-
Notifications
You must be signed in to change notification settings - Fork 8
/
docker-compose.yml
85 lines (74 loc) · 1.62 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
version: '3'
services:
simple-page:
build: ./simple-page
env_file: .env
image: swoldanski/docker-l2p-simple-page:${VERSION:-0.1.19}
deploy:
replicas: 5
ports:
- 80:80
ping-broker:
build: ./ping-broker
env_file: .env
image: swoldanski/docker-l2p-ping-broker:${VERSION:-0.1.19}
deploy:
replicas: 2
ports:
- 8000:80
rabbit-master:
image: rabbitmq:3-management
env_file: .env
deploy:
replicas: 1
ports:
- 9000:15672
rabbit-backup:
image: rabbitmq:3-management
env_file: .env
deploy:
replicas: 1
resources:
limits:
cpus: '0.5'
memory: 512M
ports:
- 9001:15672
producer:
build: ./producer
image: swoldanski/docker-l2p-producer:${VERSION:-0.1.19}
env_file: .env
deploy:
replicas: 3
consumer:
build: ./consumer
image: swoldanski/docker-l2p-consumer:${VERSION:-0.1.19}
env_file: .env
deploy:
replicas: 2
# infra & monitoring - take care, for production use you need rexternal authentication for most of them ;)
cadvisor:
image: google/cadvisor
ports:
- 10000:8080
volumes:
- /:/rootfs:ro
- /var/run:/var/run:rw
- /sys:/sys:ro
- /var/lib/docker/:/var/lib/docker:ro
deploy:
mode: global
portainer:
image: portainer/portainer
ports:
- 10001:9000
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- portainer-data:/data
deploy:
replicas: 1
placement:
constraints:
- node.role == manager
volumes:
portainer-data: