-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
40 lines (37 loc) · 940 Bytes
/
docker-compose.yml
File metadata and controls
40 lines (37 loc) · 940 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
version: '3.8'
services:
# Message Broker: Redis
redis_broker:
image: redis:7-alpine
container_name: flownode_redis
ports:
- "6379:6379"
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 5s
timeout: 3s
retries: 5
# API Gateway: FastAPI
api:
build: .
container_name: flownode_api
command: uvicorn app.main:app --host 0.0.0.0 --port 8000 --reload
ports:
- "8000:8000"
environment:
- CELERY_BROKER_URL=redis://redis_broker:6379/0
depends_on:
redis_broker:
condition: service_healthy
# Background Worker: Celery
worker:
build: .
container_name: flownode_worker
command: celery -A app.worker.celery_app worker --loglevel=info
environment:
- CELERY_BROKER_URL=redis://redis_broker:6379/0
depends_on:
redis_broker:
condition: service_healthy
api:
condition: service_started