-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
112 lines (104 loc) · 2.51 KB
/
docker-compose.yml
File metadata and controls
112 lines (104 loc) · 2.51 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
100
101
102
103
104
105
106
107
108
109
110
111
112
version: '3.7'
services:
webserver:
image: mahoney0101/threadserver:0.0.0.20
ports:
- "5000:5000"
deploy:
placement:
constraints:
- node.labels.role == worker
restart_policy:
condition: any
networks:
- overlay-network
alertapi:
image: mahoney0101/alertapi:0.0.0.6
ports:
- "5001:5001"
volumes:
- /var/run/docker.sock:/var/run/docker.sock
deploy:
placement:
constraints:
- node.labels.role == master
restart_policy:
condition: any
networks:
- overlay-network
node-exporter:
image: prom/node-exporter:v1.7.0
ports:
- "9100:9100"
command:
- --collector.textfile.directory=/etc/node-exporter/
- --collector.processes
deploy:
placement:
constraints:
- node.labels.role == worker
networks:
- overlay-network
prometheus:
image: prom/prometheus:v2.45.0
ports:
- "9090:9090"
command:
- "--config.file=/etc/prometheus/prometheus.yml"
- "--storage.tsdb.path=/prometheus"
- "--web.enable-lifecycle"
- "--enable-feature=native-histograms"
- "--web.enable-remote-write-receiver"
- "--web.enable-admin-api"
deploy:
placement:
constraints:
- node.labels.role == worker
restart_policy:
condition: any
networks:
- overlay-network
configs:
- source: prometheusconfig
target: /etc/prometheus/prometheus.yml
- source: prometheusalertrulesconfig
target: /etc/prometheus/alert_rules.yml
pushgateway:
image: prom/pushgateway:v1.7.0
ports:
- "9091:9091"
deploy:
placement:
constraints:
- node.labels.role == worker
networks:
- overlay-network
alertmanager:
image: prom/alertmanager:v0.27.0
ports:
- "9093:9093"
command:
- "--config.file=/etc/alertmanager/config.yml"
- "--storage.path=/alertmanager"
deploy:
placement:
constraints:
- node.labels.role == worker
networks:
- overlay-network
configs:
- source: alertmanagerconfig
target: /etc/alertmanager/config.yml
configs:
prometheusconfig:
file: ./stack/prometheus/prometheus.yml
external: true
alertmanagerconfig:
file: ./stack/alertmanager/config.yml
external: true
prometheusalertrulesconfig:
file: ./stack/prometheus/alert_rules.yml
external: true
networks:
overlay-network:
driver: overlay