-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathdocker-compose.yml
290 lines (285 loc) · 6.71 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
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
version: '3.3'
networks:
monitor-net:
driver: bridge
logging-net:
driver: bridge
# Volumes for persisting data, see https://docs.docker.com/engine/admin/volumes/volumes/
volumes:
mongo_data:
driver: local
es_data:
driver: local
graylog_journal:
driver: local
services:
carml:
image: carml/web:amd64
container_name: carml
ports:
- 8088:8088
links:
- jaeger
- consul
- caffe2
- caffe
- mxnet
depends_on:
- jaeger
- consul
- caffe2
- caffe
- mxnet
environment:
- PORT=8088
- TRACER_ENDPOINTS=zipkin:9411
- REGISTRY_ENDPOINTS=consul:8500
restart: unless-stopped
entrypoint: carml web -d -v
volumes:
- type: volume
source: ~/data/carml
target: /data/carml
- type: volume
source: $HOME
target: /root
caffe2:
image: carml/caffe2-agent:amd64-cpu-latest
container_name: caffe2
links:
- jaeger
- consul
restart: unless-stopped
entrypoint: caffe2-agent -d -v -l
volumes:
- type: volume
source: ~/data/carml
target: /data/carml
- type: volume
source: $HOME
target: /root
environment:
- TRACER_ENDPOINTS=jaeger:9411
- REGISTRY_ENDPOINTS=consul:8500
depends_on:
- jaeger
- consul
caffe:
image: carml/caffe-agent:amd64-cpu-latest
container_name: caffe
links:
- jaeger
- consul
restart: unless-stopped
entrypoint: caffe-agent -d -v -l
volumes:
- type: volume
source: ~/data/carml
target: /data/carml
- type: volume
source: $HOME
target: /root
environment:
- TRACER_ENDPOINTS=jaeger:9411
- REGISTRY_ENDPOINTS=consul:8500
depends_on:
- jaeger
- consul
mxnet:
image: carml/mxnet-agent:amd64-cpu-latest
container_name: mxnet
links:
- jaeger
- consul
restart: unless-stopped
entrypoint: mxnet-agent -d -v -l
volumes:
- type: volume
source: ~/data/carml
target: /data/carml
- type: volume
source: $HOME
target: /root
environment:
- TRACER_ENDPOINTS=jaeger:9411
- REGISTRY_ENDPOINTS=consul:8500
depends_on:
- jaeger
- consul
store:
image: minio/minio
container_name: store
expose:
- 9030
ports:
- 9030:9000
command: server /export
environment:
- MINIO_ACCESS_KEY=AKIAIOSFODNN7EXAMPLE
- MINIO_SECRET_KEY=wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY
volumes:
- ~/data/store:/export
- ~/data/store:/root/.minio
jaeger:
image: jaegertracing/all-in-one:latest
container_name: jaeger
environment:
- COLLECTOR_ZIPKIN_HTTP_PORT=9411
ports:
- 9411:9411
consul:
image: consul
container_name: consul
ports:
- 8500:8500
logging:
driver: "none"
prometheus:
image: prom/prometheus
container_name: prometheus
volumes:
- ./config/prometheus/:/etc/prometheus/
- ~/data/carml/prometheus_data:/prometheus
command:
- '-config.file=/etc/prometheus/prometheus.yml'
- '-storage.local.path=/prometheus'
- '-alertmanager.url=http://alertmanager:9093'
- '-storage.local.memory-chunks=100000'
restart: unless-stopped
expose:
- 9090
ports:
- 9090:9090
networks:
- monitor-net
labels:
org.label-schema.group: "monitoring"
nodeexporter:
image: prom/node-exporter
container_name: nodeexporter
volumes:
- /proc:/host/proc:ro
- /sys:/host/sys:ro
- /:/rootfs:ro
command:
- '-collector.procfs=/host/proc'
- '-collector.sysfs=/host/sys'
- '-collector.filesystem.ignored-mount-points=^/(sys|proc|dev|host|etc)($$|/)'
restart: unless-stopped
expose:
- 9100
networks:
- monitor-net
labels:
org.label-schema.group: "monitoring"
alertmanager:
image: prom/alertmanager
container_name: alertmanager
volumes:
- ./config/alertmanager/:/etc/alertmanager/
command:
- '-config.file=/etc/alertmanager/config.yml'
- '-storage.path=/alertmanager'
restart: unless-stopped
expose:
- 9093
ports:
- 9093:9093
networks:
- monitor-net
labels:
org.label-schema.group: "monitoring"
cadvisor:
image: google/cadvisor:v0.26.1
container_name: cadvisor
volumes:
- /:/rootfs:ro
- /var/run:/var/run:rw
- /sys:/sys:ro
- /var/lib/docker/:/var/lib/docker:ro
restart: unless-stopped
expose:
- 8080
ports:
- 8080:8080
networks:
- monitor-net
labels:
org.label-schema.group: "monitoring"
grafana:
image: grafana/grafana
container_name: grafana
volumes:
- ~/data/carml/grafana_data:/var/lib/grafana
environment:
- GF_SECURITY_ADMIN_USER=admin
- GF_SECURITY_ADMIN_PASSWORD=admin
- GF_USERS_ALLOW_SIGN_UP=false
restart: unless-stopped
expose:
- 3010
networks:
- monitor-net
ports:
- 3010:3000
labels:
org.label-schema.group: "monitoring"
# MongoDB: https://hub.docker.com/_/mongo/
mongo:
image: mongo:3
container_name: mongo
volumes:
- ~/data/carml/mongo_data:/data/db
networks:
- logging-net
# Elasticsearch: https://www.elastic.co/guide/en/elasticsearch/reference/5.5/docker.html
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:5.5.2
container_name: elasticsearch
volumes:
- ~/data/carml/es_data:/usr/share/elasticsearch/data
environment:
- http.host=0.0.0.0
- transport.host=localhost
- network.host=0.0.0.0
# Disable X-Pack security: https://www.elastic.co/guide/en/elasticsearch/reference/5.5/security-settings.html#general-security-settings
- xpack.security.enabled=false
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
ulimits:
memlock:
soft: -1
hard: -1
mem_limit: 1g
networks:
- logging-net
# Graylog: https://hub.docker.com/r/graylog/graylog/
graylog:
image: graylog/graylog:2.3
container_name: graylog
volumes:
- ~/data/carml/graylog_journal:/usr/share/graylog/data/journal
- ./config/graylog:/usr/share/graylog/data/config
environment:
# CHANGE ME!
- GRAYLOG_PASSWORD_SECRET=somepasswordpepper
# Password: admin
- GRAYLOG_ROOT_PASSWORD_SHA2=8c6976e5b5410415bde908bd4dee15dfb167a9c873fc4bb8a81f6f2ab448a918
- GRAYLOG_WEB_ENDPOINT_URI=http://127.0.0.1:9010/api
links:
- mongo
- elasticsearch
expose:
- 9010
ports:
# Graylog web interface and REST API
- 9010:9000
# Syslog TCP
- 514:514
# Syslog UDP
- 514:514/udp
# GELF TCP
- 12201:12201
# GELF UDP
- 12201:12201/udp
networks:
- logging-net