-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yaml
58 lines (53 loc) · 998 Bytes
/
docker-compose.yaml
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
version: "3.7"
services:
redis_cache:
image: redis:latest
volumes:
- ./data/redis/:/data
ports:
- "6379:6379"
depends_on:
- db
db:
image: postgres:latest
volumes:
- ./data/:/var/lib/postgres/data
env_file:
- .env
ports:
- "5432:5432"
message_broker:
image: rabbitmq:latest
volumes:
- ./data/rabbitmq/:/var/lib/rabbitmq/data
ports:
- "5672:5672"
worker:
build: .
command: celery -A src.core worker -l info # --loglevel=DEBUG
env_file:
- .env
volumes:
- .:/code/
healthcheck:
test: ["CMD", "celery", "status"]
interval: 10s
retries: 5
timeout: 5s
depends_on:
- message_broker
- db
- app
app:
build: .
volumes:
- .:/code/
command: python manage.py runserver 0.0.0:8000
env_file:
- .env
depends_on:
- db
- message_broker
- redis_cache
ports:
- "8000:8000"