[feat]:[FL-xxx][Redis 添加密码认证] 新增 REDIS_PASSWORD 环境变量,更新所有服务 Redis 连接 URL

This commit is contained in:
chengkai3
2026-06-28 18:10:13 +08:00
parent 1a997817ed
commit a0abbe16da
5 changed files with 29 additions and 22 deletions
+3 -2
View File
@@ -30,8 +30,8 @@ LLM_PROVIDER_API_KEYS=openai=sk-your-key
LLM_REQUEST_TIMEOUT_SECONDS=60
CHAT_CONTEXT_MESSAGE_LIMIT=12
CHAT_DEFAULT_SYSTEM_PROMPT=You are a helpful assistant.
CELERY_BROKER_URL=redis://redis:6379/0
CELERY_RESULT_BACKEND=redis://redis:6379/1
CELERY_BROKER_URL=redis://:${REDIS_PASSWORD}@redis:6379/0
CELERY_RESULT_BACKEND=redis://:${REDIS_PASSWORD}@redis:6379/1
CELERY_TIMEZONE=Asia/Shanghai
CELERY_LOG_LEVEL=INFO
CELERY_WORKER_CONCURRENCY=2
@@ -61,6 +61,7 @@ MINIO_IMAGE=minio/minio:latest
MINIO_MC_IMAGE=minio/mc:latest
REDIS_IMAGE=docker.m.daocloud.io/library/redis:7-alpine
REDIS_PORT=6379
REDIS_PASSWORD=change-this-in-production
# Redis 持久化策略:
# - 启用 AOFappendonly yes
# - 关闭 RDB 快照(save ""
+3 -2
View File
@@ -29,8 +29,8 @@ LLM_REQUEST_TIMEOUT_SECONDS=60
CHAT_CONTEXT_MESSAGE_LIMIT=12
CHAT_DEFAULT_SYSTEM_PROMPT=You are a helpful assistant.
CELERY_BROKER_URL=redis://redis:6379/0
CELERY_RESULT_BACKEND=redis://redis:6379/1
CELERY_BROKER_URL=redis://:${REDIS_PASSWORD}@redis:6379/0
CELERY_RESULT_BACKEND=redis://:${REDIS_PASSWORD}@redis:6379/1
CELERY_TIMEZONE=Asia/Shanghai
SCHEDULER_EXPIRE_INTERVAL_SECONDS=60
FLOWER_API_BASE_URL=http://flower:5555
@@ -38,6 +38,7 @@ FLOWER_API_TIMEOUT_SECONDS=10
FLOWER_BASIC_AUTH=admin:admin
WORKER_REGISTRY_TTL_SECONDS=90
CELERY_WORKER_QUEUES=default,celery
REDIS_PASSWORD=replace_me
WINE_BINARY_PATH=wine
WINE_ALLOWED_ROOT=./data/wine
+10 -8
View File
@@ -24,6 +24,8 @@ services:
- redis-server
- --appendonly
- "yes"
- --requirepass
- ${REDIS_PASSWORD}
- --save
- ""
- --stop-writes-on-bgsave-error
@@ -87,8 +89,8 @@ services:
DB_HOST: db
DB_PORT: 5432
MINIO_ENDPOINT: http://minio:9000
CELERY_BROKER_URL: redis://redis:6379/0
CELERY_RESULT_BACKEND: redis://redis:6379/1
CELERY_BROKER_URL: redis://:${REDIS_PASSWORD}@redis:6379/0
CELERY_RESULT_BACKEND: redis://:${REDIS_PASSWORD}@redis:6379/1
FLOWER_BASIC_AUTH: ${FLOWER_BASIC_AUTH}
ports:
- "${API_PORT}:8000"
@@ -122,8 +124,8 @@ services:
environment:
DB_HOST: db
DB_PORT: 5432
CELERY_BROKER_URL: redis://redis:6379/0
CELERY_RESULT_BACKEND: redis://redis:6379/1
CELERY_BROKER_URL: redis://:${REDIS_PASSWORD}@redis:6379/0
CELERY_RESULT_BACKEND: redis://:${REDIS_PASSWORD}@redis:6379/1
FLOWER_API_BASE_URL: http://flower:5555
volumes:
- ./data/app:/app/data
@@ -154,8 +156,8 @@ services:
environment:
DB_HOST: db
DB_PORT: 5432
CELERY_BROKER_URL: redis://redis:6379/0
CELERY_RESULT_BACKEND: redis://redis:6379/1
CELERY_BROKER_URL: redis://:${REDIS_PASSWORD}@redis:6379/0
CELERY_RESULT_BACKEND: redis://:${REDIS_PASSWORD}@redis:6379/1
volumes:
- ./data/app:/app/data
restart: unless-stopped
@@ -182,8 +184,8 @@ services:
depends_on:
- redis
environment:
CELERY_BROKER_URL: redis://redis:6379/0
CELERY_RESULT_BACKEND: redis://redis:6379/1
CELERY_BROKER_URL: redis://:${REDIS_PASSWORD}@redis:6379/0
CELERY_RESULT_BACKEND: redis://:${REDIS_PASSWORD}@redis:6379/1
CELERY_TIMEZONE: ${CELERY_TIMEZONE}
FLOWER_BASIC_AUTH: ${FLOWER_BASIC_AUTH:-admin:admin}
ports:
+3 -2
View File
@@ -29,8 +29,8 @@ LLM_REQUEST_TIMEOUT_SECONDS=60
CHAT_CONTEXT_MESSAGE_LIMIT=12
CHAT_DEFAULT_SYSTEM_PROMPT=You are a helpful assistant.
CELERY_BROKER_URL=redis://redis:6379/0
CELERY_RESULT_BACKEND=redis://redis:6379/1
CELERY_BROKER_URL=redis://:${REDIS_PASSWORD}@redis:6379/0
CELERY_RESULT_BACKEND=redis://:${REDIS_PASSWORD}@redis:6379/1
CELERY_TIMEZONE=Asia/Shanghai
SCHEDULER_EXPIRE_INTERVAL_SECONDS=60
FLOWER_API_BASE_URL=http://flower:5555
@@ -38,6 +38,7 @@ FLOWER_API_TIMEOUT_SECONDS=10
FLOWER_BASIC_AUTH=admin:change_me
WORKER_REGISTRY_TTL_SECONDS=90
CELERY_WORKER_QUEUES=default,celery
REDIS_PASSWORD=replace_strong_redis_password
WINE_BINARY_PATH=wine
WINE_ALLOWED_ROOT=./data/wine
+10 -8
View File
@@ -18,6 +18,8 @@ services:
- redis-server
- --appendonly
- "yes"
- --requirepass
- ${REDIS_PASSWORD}
- --save
- ""
- --stop-writes-on-bgsave-error
@@ -75,8 +77,8 @@ services:
DB_HOST: db
DB_PORT: 5432
MINIO_ENDPOINT: http://minio:9000
CELERY_BROKER_URL: redis://redis:6379/0
CELERY_RESULT_BACKEND: redis://redis:6379/1
CELERY_BROKER_URL: redis://:${REDIS_PASSWORD}@redis:6379/0
CELERY_RESULT_BACKEND: redis://:${REDIS_PASSWORD}@redis:6379/1
FLOWER_BASIC_AUTH: ${FLOWER_BASIC_AUTH}
ports:
- "${API_PORT}:8000"
@@ -102,8 +104,8 @@ services:
environment:
DB_HOST: db
DB_PORT: 5432
CELERY_BROKER_URL: redis://redis:6379/0
CELERY_RESULT_BACKEND: redis://redis:6379/1
CELERY_BROKER_URL: redis://:${REDIS_PASSWORD}@redis:6379/0
CELERY_RESULT_BACKEND: redis://:${REDIS_PASSWORD}@redis:6379/1
FLOWER_API_BASE_URL: http://flower:5555
volumes:
- ./data/app:/app/data
@@ -126,8 +128,8 @@ services:
environment:
DB_HOST: db
DB_PORT: 5432
CELERY_BROKER_URL: redis://redis:6379/0
CELERY_RESULT_BACKEND: redis://redis:6379/1
CELERY_BROKER_URL: redis://:${REDIS_PASSWORD}@redis:6379/0
CELERY_RESULT_BACKEND: redis://:${REDIS_PASSWORD}@redis:6379/1
volumes:
- ./data/app:/app/data
restart: unless-stopped
@@ -146,8 +148,8 @@ services:
depends_on:
- redis
environment:
CELERY_BROKER_URL: redis://redis:6379/0
CELERY_RESULT_BACKEND: redis://redis:6379/1
CELERY_BROKER_URL: redis://:${REDIS_PASSWORD}@redis:6379/0
CELERY_RESULT_BACKEND: redis://:${REDIS_PASSWORD}@redis:6379/1
CELERY_TIMEZONE: ${CELERY_TIMEZONE}
FLOWER_BASIC_AUTH: ${FLOWER_BASIC_AUTH:-admin:change_me}
ports: