-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathdocker-compose.yml
239 lines (221 loc) · 6.37 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
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
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
version: "3.0"
services:
grafonnet:
image: "thelastpickle/grafonnet:1.0"
volumes:
- "./dashboards/:/input:ro"
- "${BUILD_DIR}:/output"
deploy:
resources:
limits:
cpus: '0.25'
memory: 100M
prometheus:
image: prom/prometheus:v2.11.1
restart: unless-stopped
ports:
- "9090:9090"
networks:
- tlp_dashboards_net
volumes:
- "./monitoring-environment/prometheus.yml:/etc/prometheus/prometheus.yml:ro"
deploy:
resources:
limits:
cpus: '0.5'
memory: 250M
node_exporter:
image: prom/node-exporter:v0.18.1
ports:
- "9100:9100"
volumes:
- "/proc:/host/proc:ro"
- "/sys:/host/sys:ro"
- "/:/rootfs:ro"
command:
- "--path.procfs=/host/proc"
- "--path.rootfs=/rootfs"
- "--path.sysfs=/host/sys"
- "--collector.filesystem.ignored-mount-points=^/(sys|proc|dev|host|etc)($$|/)"
- "--collector.meminfo"
depends_on:
- cassandra
- cassandra2
networks:
- tlp_dashboards_net
deploy:
resources:
limits:
cpus: '0.25'
memory: 100M
node_exporter2:
image: prom/node-exporter:v0.18.1
ports:
- "9100"
volumes:
- "/proc:/host/proc:ro"
- "/sys:/host/sys:ro"
- "/:/rootfs:ro"
command:
- "--path.procfs=/host/proc"
- "--path.rootfs=/rootfs"
- "--path.sysfs=/host/sys"
- "--collector.filesystem.ignored-mount-points=^/(sys|proc|dev|host|etc)($$|/)"
- "--collector.meminfo"
depends_on:
- cassandra
- cassandra2
networks:
- tlp_dashboards_net
deploy:
resources:
limits:
cpus: '0.25'
memory: 100M
grafana:
image: grafana/grafana
restart: unless-stopped
ports:
- "3000:3000"
volumes:
- "./monitoring-environment/grafana.ini:/etc/grafana/grafana.ini:ro"
- "./monitoring-environment/provisioning/:/etc/grafana/provisioning/"
- "${DASHBOARD_DIR}:/var/lib/grafana/dashboards:ro"
networks:
- tlp_dashboards_net
environment:
- "GF_INSTALL_PLUGINS=grafana-polystat-panel"
deploy:
resources:
limits:
cpus: '0.5'
memory: 250M
cassandra:
image: cassandra:3.11.4
ports:
- "9501:9501"
- "9042:9042"
- "7000"
- "7199:7199"
volumes:
- "./cassandra-environment/jmx_prometheus_javaagent-0.12.0.jar.txt:/usr/share/jmx_prometheus_javaagent-0.12.0.jar:ro"
- "./cassandra-environment/config.yaml:/usr/share/config.yaml:ro"
- "./cassandra-environment/jmxremote.access:/etc/cassandra/jmxremote.access"
- "./cassandra-environment/jmxremote.password:/etc/cassandra/jmxremote.password"
environment:
JVM_EXTRA_OPTS: '-javaagent:/usr/share/jmx_prometheus_javaagent-0.12.0.jar=9501:/usr/share/config.yaml -Dcassandra.consistent.rangemovement=false -Dcassandra.ring_delay_ms=100 -Dcom.sun.management.jmxremote.access.file=/etc/cassandra/jmxremote.access -Djava.rmi.server.hostname=cassandra'
CASSANDRA_NUM_TOKENS: 1
CASSANDRA_SEEDS: "cassandra,cassandra2"
LOCAL_JMX: "no"
networks:
- tlp_dashboards_net
deploy:
resources:
limits:
cpus: '4'
memory: 4G
cassandra2:
image: cassandra:3.11.4
command: /bin/bash -c "echo 'Waiting for seed node' && sleep 30 && /docker-entrypoint.sh cassandra -f"
ports:
- "9501"
- "9042"
- "7000"
- "7199"
volumes:
- "./cassandra-environment/jmx_prometheus_javaagent-0.12.0.jar.txt:/usr/share/jmx_prometheus_javaagent-0.12.0.jar:ro"
- "./cassandra-environment/config.yaml:/usr/share/config.yaml:ro"
- "./cassandra-environment/jmxremote.access:/etc/cassandra/jmxremote.access"
- "./cassandra-environment/jmxremote.password:/etc/cassandra/jmxremote.password"
networks:
- tlp_dashboards_net
environment:
JVM_EXTRA_OPTS: '-javaagent:/usr/share/jmx_prometheus_javaagent-0.12.0.jar=9501:/usr/share/config.yaml -Dcassandra.consistent.rangemovement=false -Dcassandra.ring_delay_ms=100 -Djava.rmi.server.hostname=cassandra2'
CASSANDRA_NUM_TOKENS: 1
CASSANDRA_SEEDS: "cassandra,cassandra2"
LOCAL_JMX: "no"
deploy:
resources:
limits:
cpus: '4'
memory: 4G
reaper:
image: thelastpickle/cassandra-reaper:master
ports:
- "8080:8080"
- "8081:8081"
networks:
- tlp_dashboards_net
environment:
REAPER_STORAGE_TYPE: "memory"
REAPER_JMX_AUTH_USERNAME: "cassandraUser"
REAPER_JMX_AUTH_PASSWORD: "cassandraPass"
REAPER_AUTO_SCHEDULING_ENABLED: "True"
REAPER_AUTO_SCHEDULING_TIME_BEFORE_FIRST_SCHEDULE: "PT1M"
REAPER_AUTO_SCHEDULING_PERIOD_BETWEEN_POLLS: "PT1M"
REAPER_AUTO_SCHEDULING_EXCLUDED_CLUSTERS: ""
REAPER_AUTO_SCHEDULING_SCHEDULE_SPREAD_PERIOD: "PT1M"
REAPER_JMX_CREDENTIALS: "cassandraUser:cassandraPass@testcluster"
deploy:
resources:
limits:
cpus: '1.00'
memory: 1G
register-cluster:
image: thelastpickle/cassandra-reaper:master
networks:
- tlp_dashboards_net
command: ["register-clusters", "cassandra:7199", "reaper", "8080"]
deploy:
resources:
limits:
cpus: '0.25'
memory: 100M
stress:
image: thelastpickle/tlp-stress:latest
ports:
- "9500:9500"
networks:
- tlp_dashboards_net
command: "run KeyValue --rate 100 -d 1d -r .8 --host cassandra2 --keyspace tlp_stress"
depends_on:
- cassandra
- cassandra2
deploy:
resources:
limits:
cpus: '0.50'
memory: 1G
stress2:
image: thelastpickle/tlp-stress:latest
ports:
- "9500"
networks:
- tlp_dashboards_net
command: "run BasicTimeSeries --rate 100 -d 1d -r .9 --host cassandra --keyspace tlp_stress2"
depends_on:
- cassandra
- cassandra2
- stress
deploy:
resources:
limits:
cpus: '0.50'
memory: 1G
start_dependencies:
image: dadarek/wait-for-dependencies
depends_on:
- cassandra
- cassandra2
- reaper
command: cassandra:9042 cassandra2:9042 reaper:8080
networks:
- tlp_dashboards_net
deploy:
resources:
limits:
cpus: '0.1'
memory: 100M
networks:
tlp_dashboards_net:
driver: bridge