Files
filecodebox/docs/.vitepress/dist/assets/en_guide_introduction.md.BD40RLpr.js
T
2025-02-12 14:27:39 +08:00

11 lines
15 KiB
Python
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
import{_ as a,c as i,o as t,ag as s}from"./chunks/framework.BmLMQRXF.js";const g=JSON.parse('{"title":"","description":"","frontmatter":{},"headers":[],"relativePath":"en/guide/introduction.md","filePath":"en/guide/introduction.md","lastUpdated":1739330962000}'),n={name:"en/guide/introduction.md"};function l(r,e,o,h,d,p){return t(),i("div",null,e[0]||(e[0]=[s(`<div align="center"><img src="https://fastly.jsdelivr.net/gh/vastsa/FileCodeBox@V1.6/static/banners/img_1.png" alt="FileCodeBox Logo"><p><em>Share text and files anonymously with a passcode, like picking up a package</em></p><p><a href="https://github.com/vastsa/FileCodeBox/stargazers" target="_blank" rel="noreferrer"><img src="https://img.shields.io/github/stars/vastsa/FileCodeBox" alt="GitHub stars"></a><a href="https://github.com/vastsa/FileCodeBox/network" target="_blank" rel="noreferrer"><img src="https://img.shields.io/github/forks/vastsa/FileCodeBox" alt="GitHub forks"></a><a href="https://github.com/vastsa/FileCodeBox/issues" target="_blank" rel="noreferrer"><img src="https://img.shields.io/github/issues/vastsa/FileCodeBox" alt="GitHub issues"></a><a href="https://github.com/vastsa/FileCodeBox/blob/master/LICENSE" target="_blank" rel="noreferrer"><img src="https://img.shields.io/github/license/vastsa/FileCodeBox" alt="GitHub license"></a><a href="https://qm.qq.com/q/PemPzhdEIM" target="_blank" rel="noreferrer"><img src="https://img.shields.io/badge/QQ%20Group-739673698-blue.svg" alt="QQ Group"></a><a href="https://www.python.org" target="_blank" rel="noreferrer"><img src="https://img.shields.io/badge/Python-3.8+-blue.svg" alt="Python Version"></a><a href="https://fastapi.tiangolo.com" target="_blank" rel="noreferrer"><img src="https://img.shields.io/badge/FastAPI-0.68+-green.svg" alt="FastAPI"></a><a href="https://v3.vuejs.org" target="_blank" rel="noreferrer"><img src="https://img.shields.io/badge/Vue.js-3.x-brightgreen.svg" alt="Vue Version"></a></p></div><h2 id="📝-introduction" tabindex="-1">📝 Introduction <a class="header-anchor" href="#📝-introduction" aria-label="Permalink to &quot;📝 Introduction&quot;"></a></h2><p>FileCodeBox is a lightweight file sharing tool developed with FastAPI + Vue3. It allows users to share text and files easily, where recipients only need a passcode to retrieve the files, just like picking up a package from a delivery locker.</p><h2 id="🖼️-preview" tabindex="-1">🖼️ Preview <a class="header-anchor" href="#🖼️-preview" aria-label="Permalink to &quot;🖼️ Preview&quot;"></a></h2><div align="center"><h3><a href="https://github.com/vastsa/FileCodeBoxFronted" target="_blank"><img src="https://img.shields.io/badge/Frontend-FileCodeBoxFronted-blue?style=for-the-badge&amp;logo=github" alt="Frontend Repository"></a>     <a href="https://share.lanol.cn" target="_blank"><img src="https://img.shields.io/badge/Demo-share.lanol.cn-green?style=for-the-badge&amp;logo=internet-explorer" alt="Demo Site"></a></h3></div><h2 id="🎯-use-cases" tabindex="-1">🎯 Use Cases <a class="header-anchor" href="#🎯-use-cases" aria-label="Permalink to &quot;🎯 Use Cases&quot;"></a></h2><table><tr><td align="center"><h4>📁 Temporary File Sharing</h4> Quick file sharing without registration </td><td align="center"><h4>📝 Quick Text Sharing</h4> Share code snippets and text content </td><td align="center"><h4>🕶️ Anonymous Transfer</h4> Privacy-protected file transfer </td></tr><tr><td align="center"><h4>💾 Temporary Storage</h4> File storage with expiration time </td><td align="center"><h4>🔄 Cross-platform Transfer</h4> Quick file transfer between devices </td><td align="center"><h4>🌐 Private Share Service</h4> Build your own file sharing service </td></tr></table><h2 id="✨-core-features" tabindex="-1"> Core Features <a class="header-anchor" href="#✨-core-features" aria-label="Permalink to &quot;✨ Core Features&quot;"></a></h2><table><tr><td align="center"><h4>🚀 Lightweight</h4> Based on FastAPI + SQLite3 + Vue3 + ElementUI </td><td align="center"><h4>📤 Easy Upload</h4> Support copy-paste and drag-drop </td><td align="center"><h4>📦 Multiple Types</h4> Support text and various file types </td></tr><tr><td align="center"><h4>🔒 Security</h4><ul><li>IP upload limits</li><li>Error attempt limits</li><li>File expiration</li></ul></td><td align="center"><h4>🎫 Passcode Sharing</h4> Random codes with customizable limits </td><td align="center"><h4>🌍 Multi-language</h4> Support for Simplified Chinese, Traditional Chinese, and English </td></tr><tr><td align="center"><h4>🎭 Anonymous</h4> No registration required </td><td align="center"><h4>🛠 Admin Panel</h4> File and system management </td><td align="center"><h4>🐳 Docker</h4> One-click deployment </td></tr><tr><td align="center"><h4>💾 Storage Options</h4> Local, S3, OneDrive support </td><td align="center"><h4>📱 Responsive</h4> Mobile-friendly design </td><td align="center"><h4>💻 CLI Support</h4> Command-line download </td></tr></table><h2 id="🚀-quick-start" tabindex="-1">🚀 Quick Start <a class="header-anchor" href="#🚀-quick-start" aria-label="Permalink to &quot;🚀 Quick Start&quot;"></a></h2><h3 id="docker-deployment" tabindex="-1">Docker Deployment <a class="header-anchor" href="#docker-deployment" aria-label="Permalink to &quot;Docker Deployment&quot;"></a></h3><div class="language-bash vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">bash</span><pre class="shiki shiki-themes github-light github-dark vp-code" tabindex="0"><code><span class="line"><span style="--shiki-light:#6F42C1;--shiki-dark:#B392F0;">docker</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;"> run</span><span style="--shiki-light:#005CC5;--shiki-dark:#79B8FF;"> -d</span><span style="--shiki-light:#005CC5;--shiki-dark:#79B8FF;"> --restart=always</span><span style="--shiki-light:#005CC5;--shiki-dark:#79B8FF;"> -p</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;"> 12345:12345</span><span style="--shiki-light:#005CC5;--shiki-dark:#79B8FF;"> -v</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;"> /opt/FileCodeBox/:/app/data</span><span style="--shiki-light:#005CC5;--shiki-dark:#79B8FF;"> --name</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;"> filecodebox</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;"> lanol/filecodebox:beta</span></span></code></pre></div><h3 id="manual-deployment" tabindex="-1">Manual Deployment <a class="header-anchor" href="#manual-deployment" aria-label="Permalink to &quot;Manual Deployment&quot;"></a></h3><ol><li>Clone the repository</li></ol><div class="language-bash vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">bash</span><pre class="shiki shiki-themes github-light github-dark vp-code" tabindex="0"><code><span class="line"><span style="--shiki-light:#6F42C1;--shiki-dark:#B392F0;">git</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;"> clone</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;"> https://github.com/vastsa/FileCodeBox.git</span></span></code></pre></div><ol start="2"><li>Install dependencies</li></ol><div class="language-bash vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">bash</span><pre class="shiki shiki-themes github-light github-dark vp-code" tabindex="0"><code><span class="line"><span style="--shiki-light:#005CC5;--shiki-dark:#79B8FF;">cd</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;"> FileCodeBox</span></span>
<span class="line"><span style="--shiki-light:#6F42C1;--shiki-dark:#B392F0;">pip</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;"> install</span><span style="--shiki-light:#005CC5;--shiki-dark:#79B8FF;"> -r</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;"> requirements.txt</span></span></code></pre></div><ol start="3"><li>Start the service</li></ol><div class="language-bash vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">bash</span><pre class="shiki shiki-themes github-light github-dark vp-code" tabindex="0"><code><span class="line"><span style="--shiki-light:#6F42C1;--shiki-dark:#B392F0;">python</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;"> main.py</span></span></code></pre></div><h2 id="📖-usage-guide" tabindex="-1">📖 Usage Guide <a class="header-anchor" href="#📖-usage-guide" aria-label="Permalink to &quot;📖 Usage Guide&quot;"></a></h2><h3 id="share-files" tabindex="-1">Share Files <a class="header-anchor" href="#share-files" aria-label="Permalink to &quot;Share Files&quot;"></a></h3><ol><li>Open the website, click &quot;Share File&quot;</li><li>Select or drag files</li><li>Set expiration time and count</li><li>Get the passcode</li></ol><h3 id="retrieve-files" tabindex="-1">Retrieve Files <a class="header-anchor" href="#retrieve-files" aria-label="Permalink to &quot;Retrieve Files&quot;"></a></h3><ol><li>Open the website, enter passcode</li><li>Click retrieve</li><li>Download file or view text</li></ol><h3 id="admin-panel" tabindex="-1">Admin Panel <a class="header-anchor" href="#admin-panel" aria-label="Permalink to &quot;Admin Panel&quot;"></a></h3><ol><li>Visit <code>/admin</code></li><li>Enter admin password</li><li>Manage files and settings</li></ol><h2 id="🛠-development-guide" tabindex="-1">🛠 Development Guide <a class="header-anchor" href="#🛠-development-guide" aria-label="Permalink to &quot;🛠 Development Guide&quot;"></a></h2><h3 id="project-structure" tabindex="-1">Project Structure <a class="header-anchor" href="#project-structure" aria-label="Permalink to &quot;Project Structure&quot;"></a></h3><div class="language- vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang"></span><pre class="shiki shiki-themes github-light github-dark vp-code" tabindex="0"><code><span class="line"><span>FileCodeBox/</span></span>
<span class="line"><span>├── apps/ # Application code</span></span>
<span class="line"><span> ├── admin/ # Admin backend</span></span>
<span class="line"><span> └── base/ # Base functions</span></span>
<span class="line"><span>├── core/ # Core functions</span></span>
<span class="line"><span>├── data/ # Data directory</span></span>
<span class="line"><span>└── fcb-fronted/ # Frontend code</span></span></code></pre></div><h3 id="development-environment" tabindex="-1">Development Environment <a class="header-anchor" href="#development-environment" aria-label="Permalink to &quot;Development Environment&quot;"></a></h3><ul><li>Python 3.8+</li><li>Node.js 14+</li><li>Vue 3</li><li>FastAPI</li></ul><h3 id="local-development" tabindex="-1">Local Development <a class="header-anchor" href="#local-development" aria-label="Permalink to &quot;Local Development&quot;"></a></h3><ol><li>Backend development</li></ol><div class="language-bash vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">bash</span><pre class="shiki shiki-themes github-light github-dark vp-code" tabindex="0"><code><span class="line"><span style="--shiki-light:#6F42C1;--shiki-dark:#B392F0;">python</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;"> main.py</span></span></code></pre></div><ol start="2"><li>Frontend development</li></ol><div class="language-bash vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">bash</span><pre class="shiki shiki-themes github-light github-dark vp-code" tabindex="0"><code><span class="line"><span style="--shiki-light:#005CC5;--shiki-dark:#79B8FF;">cd</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;"> fcb-fronted</span></span>
<span class="line"><span style="--shiki-light:#6F42C1;--shiki-dark:#B392F0;">npm</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;"> install</span></span>
<span class="line"><span style="--shiki-light:#6F42C1;--shiki-dark:#B392F0;">npm</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;"> run</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;"> dev</span></span></code></pre></div><h2 id="🤝-contributing" tabindex="-1">🤝 Contributing <a class="header-anchor" href="#🤝-contributing" aria-label="Permalink to &quot;🤝 Contributing&quot;"></a></h2><ol><li>Fork the project</li><li>Create your feature branch <code>git checkout -b feature/xxx</code></li><li>Commit your changes <code>git commit -m &#39;Add xxx&#39;</code></li><li>Push to the branch <code>git push origin feature/xxx</code></li><li>Open a Pull Request</li></ol><h2 id="❓-faq" tabindex="-1">❓ FAQ <a class="header-anchor" href="#❓-faq" aria-label="Permalink to &quot;❓ FAQ&quot;"></a></h2><h3 id="q-how-to-modify-upload-size-limit" tabindex="-1">Q: How to modify upload size limit? <a class="header-anchor" href="#q-how-to-modify-upload-size-limit" aria-label="Permalink to &quot;Q: How to modify upload size limit?&quot;"></a></h3><p>A: Change <code>uploadSize</code> in admin panel</p><h3 id="q-how-to-configure-storage-engine" tabindex="-1">Q: How to configure storage engine? <a class="header-anchor" href="#q-how-to-configure-storage-engine" aria-label="Permalink to &quot;Q: How to configure storage engine?&quot;"></a></h3><p>A: Select storage engine and configure parameters in admin panel</p><h3 id="q-how-to-backup-data" tabindex="-1">Q: How to backup data? <a class="header-anchor" href="#q-how-to-backup-data" aria-label="Permalink to &quot;Q: How to backup data?&quot;"></a></h3><p>A: Backup the <code>data</code> directory</p><p>For more questions, visit <a href="https://github.com/vastsa/FileCodeBox/wiki/%E5%B8%B8%E8%A7%81%E9%97%AE%E9%A2%98" target="_blank" rel="noreferrer">Wiki</a></p><h2 id="😀-project-statistics-and-analytics" tabindex="-1">😀 Project Statistics and Analytics <a class="header-anchor" href="#😀-project-statistics-and-analytics" aria-label="Permalink to &quot;😀 Project Statistics and Analytics&quot;"></a></h2><div align="center"><a href="https://hellogithub.com/repository/75ad7ffedd404a6485b4d621ec5b47e6" target="_blank"><img src="https://api.hellogithub.com/v1/widgets/recommend.svg?rid=75ad7ffedd404a6485b4d621ec5b47e6&amp;claim_uid=beSz6INEkCM4mDH" alt="FeaturedHelloGitHub" style="width:200px;height:45px;" width="200" height="45"></a><p><img src="https://repobeats.axiom.co/api/embed/7a6c92f1d96ee57e6fb67f0df371528397b0c9ac.svg" alt="Repobeats"></p><p><a href="https://star-history.com/#vastsa/FileCodeBox&amp;Date" target="_blank" rel="noreferrer"><img src="https://api.star-history.com/svg?repos=vastsa/FileCodeBox&amp;type=Date" alt="Star History"></a></p></div><h2 id="📜-disclaimer" tabindex="-1">📜 Disclaimer <a class="header-anchor" href="#📜-disclaimer" aria-label="Permalink to &quot;📜 Disclaimer&quot;"></a></h2><p>This project is open-source for learning purposes only. It should not be used for any illegal purposes. The author is not responsible for any consequences. Please retain the project address and copyright information when using it.</p>`,50)]))}const u=a(n,[["render",l]]);export{g as __pageData,u as default};