Skip to content

Deployment Tutorial

vastsa edited this page Jun 17, 2024 · 3 revisions

1Panel One-Click Deployment

Go to Application Store -> Utility Tools -> FileCodeBox img_6.png Update: Container -> Select -> More -> Edit -> Force Pull Image -> Confirm

BaoTa Application Store One-Click Deployment

Current version is 1.6 img

Docker One-Click Deployment

Version 2.x, under improvement

Default information

Backend address: /#/admin

Admin password: FileCodeBox2023

Supports AMD & ARM

One-Click Installation

docker run -d --restart=always -p 12345:12345 -v /opt/FileCodeBox/:/app/data --name filecodebox lanol/filecodebox:beta

One-Click Update

docker pull lanol/filecodebox:beta && docker stop filecodebox && docker rm filecodebox && docker run -d --restart=always -p 12345:12345 -v /opt/FileCodeBox/:/app/data --name filecodebox lanol/filecodebox:beta

Version 1.6 for AMD

docker run -d --restart=always -p 12345:12345 -v /opt/FileCodeBox/:/app/data --name filecodebox lanol/filecodebox:latest

Version 1.6 for ARM

docker run -d --restart=always -p 12345:12345 -v /opt/FileCodeBox/:/app/data --name filecodebox lanol/filecodebox:arm

Update Method

// Update container
docker pull lanol/filecodebox:beta
// Stop and remove container
docker stop filecodebox && docker rm filecodebox
// Re-run container
docker run -d --restart=always -p 12345:12345 -v /opt/FileCodeBox/:/app/data --name filecodebox lanol/filecodebox:latest

Version 1.6 Notes

This version has significant changes. If you encounter problems, try clearing the /opt/FileCodeBox directory and feel free to report any issues. Note: For first-time installation, check Docker logs to get the initial password and backend address. Refer to the command below:

docker logs filecodebox

Local File List in Backend: To display, move server files to the /opt/FileCodeBox/data/locals directory.

Configuration File (For versions 1.7 and below)

To modify the configuration, save the following content as a .env file and place it in the /opt/FileCodeBox/ directory, then restart the container. If not using Docker, create a data folder in the project directory and create the .env file within that folder.

# Port
PORT=12345
# Sqlite database file
DATABASE_URL=sqlite+aiosqlite:///database.db
# Static files directory
DATA_ROOT=./static
# Static files URL
STATIC_URL=/static
# Enable upload
ENABLE_UPLOAD=True
# Error count
ERROR_COUNT=5
# Error limit in minutes
ERROR_MINUTE=10
# Upload count
UPLOAD_COUNT=60
# Upload limit in minutes
UPLOAD_MINUTE=1
# Interval to delete expired files (minutes)
DELETE_EXPIRE_FILES_INTERVAL=10
# Admin address
ADMIN_ADDRESS=admin
# Admin password
ADMIN_PASSWORD=admin
# File size limit, default 10MB
FILE_SIZE_LIMIT=10
# Website title
TITLE=文件快递柜
# Website description
DESCRIPTION=FileCodeBox, 文件快递柜, 密码传送箱, 匿名密码分享文本, 文件, 图片, 视频, 音频, 压缩包等文件
# Website keywords
KEYWORDS=FileCodeBox, 文件快递柜, 密码传送箱, 匿名密码分享文本, 文件, 图片, 视频, 音频, 压缩包等文件
# Storage engine
STORAGE_ENGINE=filesystem
# Parameters for Aliyun OSS if used:
# Aliyun account AccessKey
KeyId=Your Aliyun Account AccessKey
# Aliyun account AccessKeySecret
KeySecret=Your Aliyun Account AccessKeySecret
# Region node of Aliyun OSS Bucket
OSS_ENDPOINT=Node of the Aliyun OSS Bucket
# BucketName of Aliyun OSS Bucket
BUCKET_NAME=Your Aliyun OSS Bucket Name