feat: Docker 部署完整环境变量 — 不再依赖 backend/.env

docker-compose.yml 新增 ADMIN_PASSWORD/INTERNAL_SERVICE_TOKEN 等关键变量,
.docker.env.example 覆盖所有可配置项,确保容器内各服务启动不 panic。

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
2026-05-30 09:10:50 +08:00
parent 6a83624579
commit 3a1287dd24
3 changed files with 69 additions and 7 deletions
+25 -3
View File
@@ -9,12 +9,20 @@ LLM_API_KEY=sk-xxxxx
LLM_MODEL=gpt-4o
LLM_FALLBACK_MODEL=gpt-4o-mini
# ========== 数据库密码 ==========
POSTGRES_PASSWORD=change-me-to-random-password
# ========== 管理员账号(必填) ==========
ADMIN_USERNAME=admin
ADMIN_PASSWORD=change-me-to-secure-password
ADMIN_NICKNAME=管理员
# ========== JWT ==========
# ========== 安全密钥(必填) ==========
JWT_SECRET=change-me-to-random-secret-string
JWT_EXPIRY_HOURS=720
INTERNAL_SERVICE_TOKEN=change-me-to-random-token
# ========== 数据库 ==========
POSTGRES_USER=cyrene
POSTGRES_PASSWORD=change-me-to-random-password
POSTGRES_DB=cyrene_ai
# ========== Redis ==========
REDIS_PASSWORD=
@@ -23,5 +31,19 @@ REDIS_PASSWORD=
MINIO_ACCESS_KEY=minioadmin
MINIO_SECRET_KEY=change-me-to-random-password
# ========== 注册与访问控制 ==========
REGISTRATION_ENABLED=false
ALLOWED_ORIGINS=http://localhost:5173,http://localhost:9090
# ========== WebSocket ==========
WS_MAX_CONNECTIONS=1000
SESSION_IDLE_TIMEOUT_MIN=30
# ========== 后台自主思考 ==========
ENABLE_BACKGROUND_THINKING=true
# ========== Webhook(可选) ==========
WEBHOOK_API_KEY=
# ========== Caddy / ACME(有域名时填写) ==========
ACME_EMAIL=admin@example.com