-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathinfra.yml
61 lines (61 loc) · 1.44 KB
/
infra.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
version: '2'
services:
back01:
container_name: back01
build:
context: demo
# Use an image built from the specified dockerfile in the `polling-app-server` directory.
dockerfile: Dockerfile
image: demo:latest
ports:
- 9000:8080
networks:
- backend
- frontend
front01:
container_name: front01
build:
context: srv1
dockerfile: Dockerfile
image: srv1:latest
ports:
- 9001:8080
networks:
- frontend
links:
- back01:back01
front02:
container_name: front02
build:
context: srv2
dockerfile: Dockerfile
image: srv2:latest
ports:
- 9002:8080
networks:
- frontend
links:
- back01:back01
haproxy:
container_name: myproxy
build:
context: haproxy
dockerfile: Dockerfile
image: myproxy:latest
volumes:
- "~/Documents/myinfra/conf/haproxy:/etc/haproxy"
- "~/Documents/myinfra/logs/haproxy/:/dev/log"
links:
- back01:back01
- front01:front01
- front02:front02
ports:
- "80:80"
- "443:443"
networks:
- frontend
networks:
frontend:
driver: bridge
backend:
driver: bridge