-
Notifications
You must be signed in to change notification settings - Fork 2
/
docker-compose.yml
97 lines (91 loc) · 1.9 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
93
94
95
96
97
version: '3'
services:
response:
build:
context: .
dockerfile: Dockerfile.response
image: response
entrypoint: bash
command: /app/startup.sh --watch
expose:
- 8000
depends_on:
db:
condition: service_healthy
env_file: .env
healthcheck:
test: curl -f http://localhost:8000/ht/ || exit 1
interval: 15s
timeout: 10s
retries: 3
start_period: 30s
volumes:
- ./:/app
- ../:/response
- pypd:/app/pypd
stdin_open: true
tty: true
restart: always
nginx:
build:
context: .
dockerfile: Dockerfile.nginx
image: response-nginx
depends_on:
response:
condition: service_healthy
environment:
APP_HOST: response
APP_PORT: 8000
healthcheck:
test: curl -f http://localhost/nginx-health || exit 1
interval: 15s
timeout: 10s
retries: 3
start_period: 30s
volumes:
- ./nginx/webpack/dist:/app/opgincidentresponse/static
ports:
- 80:80
cron:
build:
context: .
dockerfile: Dockerfile.cron
image: cron
container_name: cron
depends_on:
- response
tty: true
db:
image: "postgres:13"
container_name: postgres
healthcheck:
test: pg_isready --username=api --dbname=api
interval: 10s
timeout: 5s
retries: 5
ports:
- "5432:5432"
volumes:
- postgres_data_13_vol:/var/lib/postgresql/data/
environment:
POSTGRES_PASSWORD: postgres
POSTGRES_DB: postgres
POSTGRES_USER: postgres
PGPASSWORD: postgres
ngrok:
image: ngrok/ngrok:latest
restart: unless-stopped
command:
- "http"
- "http://response:8000"
container_name: ngrok
env_file: .env
ports:
- "4040:4040"
depends_on:
response:
condition: service_healthy
volumes:
postgres_data_13_vol:
pypd: