Commit ce7893ee authored by yangjianbo's avatar yangjianbo
Browse files

feat(部署): 支持通过环境变量配置挂载的配置文件路径

- docker-compose.yml 配置文件挂载路径改为 ${CONFIG_FILE:-./config.yaml}
- .env.example 添加 CONFIG_FILE 配置项,方便用户指定自定义配置文件

🤖 Generated with [Claude Code](https://claude.com/claude-code

)
Co-Authored-By: default avatarClaude Opus 4.5 <noreply@anthropic.com>
parent 4c1293a7
......@@ -58,6 +58,14 @@ ADMIN_PASSWORD=
JWT_SECRET=
JWT_EXPIRE_HOUR=24
# -----------------------------------------------------------------------------
# Configuration File (Optional)
# -----------------------------------------------------------------------------
# Path to custom config file (relative to docker-compose.yml directory)
# Copy config.example.yaml to config.yaml and modify as needed
# Leave unset to use default ./config.yaml
#CONFIG_FILE=./config.yaml
# -----------------------------------------------------------------------------
# Gemini OAuth (OPTIONAL, required only for Gemini OAuth accounts)
# -----------------------------------------------------------------------------
......
......@@ -29,7 +29,9 @@ services:
# Data persistence (config.yaml will be auto-generated here)
- sub2api_data:/app/data
# Mount custom config.yaml (optional, overrides auto-generated config)
- ./config.yaml:/app/data/config.yaml:ro
# Set CONFIG_FILE in .env to specify a custom config file path
# Default: ./config.yaml (copy from config.example.yaml and modify)
- ${CONFIG_FILE:-./config.yaml}:/app/data/config.yaml:ro
environment:
# =======================================================================
# Auto Setup (REQUIRED for Docker deployment)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment