-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
72 lines (67 loc) · 1.46 KB
/
docker-compose.yml
File metadata and controls
72 lines (67 loc) · 1.46 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
version: '3.8'
services:
webserver:
image: ${CONTAINER_REGISTRY_ACCOUNT}/ws:${WS_TAG}
container_name: proxy_server
restart: unless-stopped
depends_on:
- microservice1
- microservice2
build:
context: web
dockerfile: Dockerfile
env_file:
- web/.env
ports:
- 80:8080
networks:
- demoNet
microservice1:
image: ${CONTAINER_REGISTRY_ACCOUNT}/ms1:${MS1_TAG}
restart: unless-stopped
deploy:
replicas: ${MS1_REPLICAS}
build:
context: micro1
dockerfile: Dockerfile
env_file:
- micro1/.env
networks:
- demoNet
# healthcheck:
# test: wget --spider http://localhost:8000/health || exit 1
# interval: 1m30s
# timeout: 30s
# retries: 5
# start_period: 30s
microservice2:
image: ${CONTAINER_REGISTRY_ACCOUNT}/ms2:${MS2_TAG}
restart: unless-stopped
deploy:
replicas: ${MS2_REPLICAS}
build:
context: micro2
dockerfile: Dockerfile
env_file:
- micro2/.env
networks:
- demoNet
fallback:
image: ${CONTAINER_REGISTRY_ACCOUNT}/fallback:${FB_TAG}
restart: unless-stopped
deploy:
replicas: ${FB_REPLICAS}
build:
context: fallback
dockerfile: Dockerfile
env_file:
- fallback/.env
networks:
- demoNet
networks:
demoNet:
driver: bridge
ipam:
config:
- subnet: 17.22.0.0/16
gateway: 17.22.0.1