-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
79 lines (73 loc) · 1.46 KB
/
docker-compose.yml
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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
volumes:
nginx-shared:
services:
nginx:
image: nginx:alpine
hostname: nginx
ports:
- "8000:8000"
volumes:
- ./docker/nginx/nginx.conf:/etc/nginx/nginx.conf:ro
- nginx-shared:/nginx
depends_on:
- web
db:
image: postgres:16-alpine
ports:
- "5432:5432"
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
healthcheck:
test: [ "CMD", "pg_isready" ]
timeout: 5s
retries: 3
# Only for development purposes
rabbitmq:
image: rabbitmq:alpine
ports:
- "5672:5672"
healthcheck:
test: rabbitmq-diagnostics -q ping
interval: 10s
timeout: 30s
retries: 5
redis:
image: redis:alpine
ports:
- "6379:6379"
command:
- --appendonly yes
healthcheck:
test: [ "CMD", "redis-cli", "ping" ]
timeout: 5s
retries: 3
web:
build:
context: .
dockerfile: docker/web/Dockerfile
env_file:
- .env
working_dir: /app
ports:
- "8888:8888"
volumes:
- nginx-shared:/nginx
depends_on:
redis:
condition: service_healthy
db:
condition: service_healthy
rabbitmq:
condition: service_healthy
command: docker/web/run_web.sh
dramatiq-worker:
build:
context: .
dockerfile: docker/web/Dockerfile
env_file:
- .env
depends_on:
- redis
command:
docker/web/dramatiq/worker/run.sh