-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
99 lines (95 loc) · 2.38 KB
/
Copy pathdocker-compose.yml
File metadata and controls
99 lines (95 loc) · 2.38 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
94
95
96
97
98
99
services:
mapda-nginx:
image: mapda:nginx
build:
context: ./deploy/nginx
dockerfile: Dockerfile
container_name: mapda-nginx
env_file:
- .env
environment:
ACTIVE_COLOR: blue
ports:
- "17200:80"
volumes:
- nginx-active:/etc/nginx/active
- minio-data:/data
networks:
- mapda-net
restart: unless-stopped
mapda-server-blue:
image: mapda-server:blue
build:
context: .
dockerfile: Dockerfile
args:
BUILDKIT_INLINE_CACHE: "1"
container_name: mapda-server-blue
env_file:
- .env
environment:
DB_ENDPOINT: host.docker.internal
DB_PORT: "3306"
DB_NAME: mapda
REDIS_HOST: mapda-nginx
REDIS_PORT: "6379"
MINIO_ENDPOINT: http://mapda-nginx:9000
MINIO_BUCKET: mapda-bucket
APP_PUBLIC_URL: ${APP_PUBLIC_URL:-http://localhost:17200}
extra_hosts:
- "host.docker.internal:host-gateway"
volumes:
- ./secrets:/app/secrets:ro
networks:
- mapda-net
depends_on:
mapda-nginx:
condition: service_started
healthcheck:
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:8000/health', timeout=5)"]
interval: 10s
timeout: 5s
retries: 12
start_period: 20s
restart: unless-stopped
mapda-server-green:
image: mapda-server:green
build:
context: .
dockerfile: Dockerfile
args:
BUILDKIT_INLINE_CACHE: "1"
container_name: mapda-server-green
env_file:
- .env
environment:
DB_ENDPOINT: host.docker.internal
DB_PORT: "3306"
DB_NAME: mapda
REDIS_HOST: mapda-nginx
REDIS_PORT: "6379"
MINIO_ENDPOINT: http://mapda-nginx:9000
MINIO_BUCKET: mapda-bucket
APP_PUBLIC_URL: ${APP_PUBLIC_URL:-http://localhost:17200}
extra_hosts:
- "host.docker.internal:host-gateway"
volumes:
- ./secrets:/app/secrets:ro
networks:
- mapda-net
depends_on:
mapda-nginx:
condition: service_started
healthcheck:
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:8000/health', timeout=5)"]
interval: 10s
timeout: 5s
retries: 12
start_period: 20s
restart: unless-stopped
networks:
mapda-net:
name: mapda-net
volumes:
nginx-active:
minio-data: