feat: 添加rustfs环境配置文件及部署配置

添加rustfs.env环境变量文件、env.cfg配置文件及stack.yml部署文件
用于配置rustfs服务的运行环境、镜像标签及容器部署参数
This commit is contained in:
2025-09-06 12:32:01 +08:00
parent bab6aa41aa
commit beea176c09
3 changed files with 29 additions and 0 deletions

7
rustfs/env.cfg Normal file
View File

@@ -0,0 +1,7 @@
IMAGE_TAG=rustfs/rustfs:alpha
IMAGE_TAG_LTS=rustfs/rustfs:latest
Volumes_Path=/data/volumes/rustfs
RUSTFS_SERVER_DOMAINS=rustfs.example.com
RUSTFS_CONSOLE_ENABLE=true
RUSTFS_SECRET_KEY=rustfsadmin
RUSTFS_ACCESS_KEY=rustfsadmin

7
rustfs/rustfs.env Normal file
View File

@@ -0,0 +1,7 @@
RUSTFS_ACCESS_KEY=rustfsadmin
RUSTFS_SECRET_KEY=rustfsadmin
RUSTFS_VOLUMES="/data/rustfs{0...3}"
RUSTFS_ADDRESS=":7000"
RUSTFS_CONSOLE_ENABLE=true
RUST_LOG=error
RUSTFS_OBS_LOG_DIRECTORY="/var/logs/rustfs/"

15
rustfs/stack.yml Normal file
View File

@@ -0,0 +1,15 @@
services:
rustfs:
image: ${IMAGE_TAG}
environment:
- RUSTFS_SERVER_DOMAINS=${RUSTFS_SERVER_DOMAINS}
- RUSTFS_CONSOLE_ENABLE=${RUSTFS_CONSOLE_ENABLE}
- RUSTFS_SECRET_KEY=${RUSTFS_SECRET_KEY}
- RUSTFS_ACCESS_KEY=${RUSTFS_ACCESS_KEY}
volumes:
- ${Volumes_Path}/data:/data
ports:
- '50900:7000'
container_name: rustfs_container
restart: always
command: '--address :7000 --console-enable --server-domains ${RUSTFS_SERVER_DOMAINS} --access-key ${RUSTFS_ACCESS_KEY} --secret-key ${RUSTFS_SECRET_KEY} /data'