fix celery
This commit is contained in:
@@ -85,7 +85,7 @@ services:
|
||||
max-size: "10m"
|
||||
max-file: "3"
|
||||
|
||||
# Celery Worker(后台任务处理,禁用健康检查避免与 api 共用镜像的 8000 端口检查冲突)
|
||||
# Celery Worker(后台任务处理,禁用镜像内置的 8000 端口健康检查,改用 celery inspect ping)
|
||||
celery-worker:
|
||||
build:
|
||||
context: .
|
||||
@@ -106,6 +106,12 @@ services:
|
||||
condition: service_healthy
|
||||
api:
|
||||
condition: service_healthy
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "celery -A tasks.celery_app inspect ping --timeout 10 2>/dev/null | grep -q pong || exit 1"]
|
||||
interval: 30s
|
||||
timeout: 15s
|
||||
retries: 3
|
||||
start_period: 30s
|
||||
networks:
|
||||
- life-echo-network
|
||||
logging:
|
||||
|
||||
Reference in New Issue
Block a user