-
-
Notifications
You must be signed in to change notification settings - Fork 12
/
docker-compose.yml
92 lines (82 loc) · 1.49 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
80
81
82
83
84
85
86
87
88
89
90
91
92
x-app: &app-config
build: .
depends_on:
- postgres
- redis
env_file:
- .env
environment:
POSTGRES_USER: postgres
POSTGRES_HOST: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: flagging
REDIS_URL: redis://redis:6379
FLASK_ENV: ${FLASK_ENV:-development}
BASIC_AUTH_USERNAME: ${BASIC_AUTH_USERNAME:-development}
GUNICORN_CMD_ARGS: --reload
networks:
- db
- redis
restart: unless-stopped
stop_grace_period: "5s"
tty: true
volumes:
- .:/app
version: "3.3"
services:
web:
<<: *app-config
ports:
- "127.0.0.1:80:80"
- "127.0.0.1:443:443"
depends_on:
- postgres
links:
- postgres
- redis
- celeryworker
redis:
image: redis:alpine
networks:
- redis
postgres:
image: postgres:16
environment:
POSTGRES_USER: postgres
POSTGRES_HOST: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: flagging
env_file:
- .env
tty: true
networks:
- db
volumes:
- postgres:/var/lib/postgresql/data
pgadmin:
image: dpage/pgadmin4
depends_on:
- postgres
env_file:
- .env
networks:
- db
ports:
- "5050:80"
volumes:
- pgadmin:/var/lib/pgadmin
celeryworker:
<<: *app-config
entrypoint: ["flask", "celery", "worker"]
ports:
- 5555:5555
depends_on:
- redis
networks:
redis:
driver: bridge
db:
driver: bridge
volumes:
postgres: {}
pgadmin: {}