-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
93 lines (93 loc) · 2.01 KB
/
docker-compose.yml
File metadata and controls
93 lines (93 loc) · 2.01 KB
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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
services:
othello_postgres:
container_name: othello_postgres
image: postgres:latest
environment:
- POSTGRES_DB=othello
- POSTGRES_USER=othello
- POSTGRES_PASSWORD=pwd
volumes:
- othello_pgdata:/var/lib/postgresql
ports:
- "5432:5432"
networks:
- othello_network
healthcheck:
test: ["CMD-SHELL", "pg_isready -U othello -d othello"]
interval: 5s
timeout: 5s
retries: 5
othello_redis:
container_name: othello_redis
image: redis:latest
expose:
- "6379"
networks:
- othello_network
othello_django:
container_name: othello_django
image: othello_django
build:
context: ../../
dockerfile: config/docker/Dockerfile
ports:
- "8000:8000"
depends_on:
othello_postgres:
condition: service_healthy
othello_redis:
condition: service_started
volumes:
- ../../:/app
working_dir: /app
networks:
- othello_network
entrypoint:
[
"/bin/sh",
"-c",
"/app/config/docker/entrypoint.sh"
]
othello_celery:
container_name: othello_celery
image: othello_django
depends_on:
othello_postgres:
condition: service_healthy
othello_redis:
condition: service_started
volumes:
- ../../:/app
working_dir: /app
networks:
- othello_network
entrypoint:
[
"/bin/sh",
"-c",
"uv run celery --app othello worker -l INFO -Ofair"
]
othello_gamequeue:
container_name: othello_gamequeue
image: othello_django
depends_on:
othello_postgres:
condition: service_healthy
othello_redis:
condition: service_started
volumes:
- ../../:/app
working_dir: /app
networks:
- othello_network
entrypoint:
[
"/bin/sh",
"-c",
"uv run celery --app othello worker -l INFO -Ofair --concurrency=2 -Q game_queue"
]
volumes:
othello_pgdata:
networks:
othello_network:
driver: bridge