-
Notifications
You must be signed in to change notification settings - Fork 10
/
docker-compose-prometheus-jaeger.yml
282 lines (262 loc) · 8.88 KB
/
docker-compose-prometheus-jaeger.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
version: '3'
services:
# Ocelot
## Serves as a collector for traces
agent:
image: inspectit/inspectit-ocelot-agent:${INSPECTIT_OCELOT_VERSION}
container_name: agent
deploy:
resources:
limits:
memory: 128M
volumes:
- agent-vol:/agent
## Fetches the configuration
ocelot-config-server:
restart: always
image: inspectit/inspectit-ocelot-configurationserver:${INSPECTIT_OCELOT_VERSION}
container_name: ocelot-config-server
deploy:
resources:
limits:
memory: 512M
environment:
- INSPECTIT_CONFIG_SERVER_WORKING_DIRECTORY=/configuration-server
- INSPECTIT_CONFIG_SERVER_DEFAULT_USER_PASSWORD=demo
volumes:
- ./configuration-server:/configuration-server
ports:
- 8090:8090
## Self Monitoring
ocelot-eum-server:
restart: always
image: inspectit/inspectit-ocelot-eum-server:${INSPECTIT_OCELOT_VERSION}
container_name: ocelot-eum-server
hostname: ocelot-eum-server
environment:
- INSPECTIT_EUM_SERVER_EXPORTERS_METRICS_PROMETHEUS_ENABLED=ENABLED
- INSPECTIT_EUM_SERVER_EXPORTERS_METRICS_PROMETHEUS_PORT=9097
- INSPECTIT_EUM_SERVER_EXPORTERS_METRICS_PROMETHEUS_HOST=0.0.0.0
- INSPECTIT_EUM_SERVER_EXPORTERS_TRACING_JAEGER_GRPC=jaeger:14250
deploy:
resources:
limits:
memory: 512M
volumes:
- ./eum-server:/eum-server
ports:
- 8085:8085
- 9097:9097
# Petclinic
config-server:
restart: always
image: inspectit/spring-petclinic-config-server:${INSPECTIT_PETCLINIC_VERSION}
container_name: config-server
hostname: config-server
environment:
- INSPECTIT_SERVICE_NAME=config-server
- INSPECTIT_CONFIG_HTTP_URL=http://ocelot-config-server:8090/api/v1/agent/configuration
- INSPECTIT_EXPORTERS_METRICS_PROMETHEUS_ENABLED=ENABLED
- INSPECTIT_EXPORTERS_METRICS_PROMETHEUS_PORT=9096
- INSPECTIT_EXPORTERS_TRACING_JAEGER_URL=http://jaeger:14268/api/traces
deploy:
resources:
limits:
memory: 1024M
depends_on:
- agent
- ocelot-config-server
entrypoint: ["./dockerize", "java", "-javaagent:/agent/inspectit-ocelot-agent.jar", "org.springframework.boot.loader.JarLauncher"]
volumes:
- agent-vol:/agent
ports:
- 8888:8888
- 9096:9096
discovery-server:
restart: always
image: inspectit/spring-petclinic-discovery-server:${INSPECTIT_PETCLINIC_VERSION}
container_name: discovery-server
hostname: discovery-server
environment:
- INSPECTIT_SERVICE_NAME=discovery-server
- INSPECTIT_CONFIG_HTTP_URL=http://ocelot-config-server:8090/api/v1/agent/configuration
- INSPECTIT_EXPORTERS_METRICS_PROMETHEUS_ENABLED=ENABLED
- INSPECTIT_EXPORTERS_METRICS_PROMETHEUS_PORT=9095
- INSPECTIT_EXPORTERS_TRACING_JAEGER_URL=http://jaeger:14268/api/traces
deploy:
resources:
limits:
memory: 1024M
depends_on:
- agent
- ocelot-config-server
- config-server
entrypoint: ["./dockerize","-wait=tcp://config-server:8888","-timeout=120s","--","java", "-javaagent:/agent/inspectit-ocelot-agent.jar", "org.springframework.boot.loader.JarLauncher"]
volumes:
- agent-vol:/agent
ports:
- 8761:8761
- 9095:9095
customers-service:
restart: always
image: inspectit/spring-petclinic-customers-service:${INSPECTIT_PETCLINIC_VERSION}
container_name: customers-service
hostname: customers-service
environment:
- INSPECTIT_SERVICE_NAME=customers-service
- INSPECTIT_CONFIG_HTTP_URL=http://ocelot-config-server:8090/api/v1/agent/configuration
- INSPECTIT_EXPORTERS_METRICS_PROMETHEUS_ENABLED=ENABLED
- INSPECTIT_EXPORTERS_METRICS_PROMETHEUS_PORT=9091
- INSPECTIT_EXPORTERS_TRACING_JAEGER_URL=http://jaeger:14268/api/traces
deploy:
resources:
limits:
memory: 1024M
depends_on:
- agent
- ocelot-config-server
- config-server
- discovery-server
entrypoint: ["./dockerize","-wait=tcp://discovery-server:8761","-timeout=120s","--","java", "-javaagent:/agent/inspectit-ocelot-agent.jar", "org.springframework.boot.loader.JarLauncher"]
volumes:
- agent-vol:/agent
ports:
- 8081:8081
- 9091:9091
visits-service:
restart: always
image: inspectit/spring-petclinic-visits-service:${INSPECTIT_PETCLINIC_VERSION}
container_name: visits-service
hostname: visits-service
environment:
- INSPECTIT_SERVICE_NAME=visits-service
- INSPECTIT_CONFIG_HTTP_URL=http://ocelot-config-server:8090/api/v1/agent/configuration
- INSPECTIT_EXPORTERS_METRICS_PROMETHEUS_ENABLED=ENABLED
- INSPECTIT_EXPORTERS_METRICS_PROMETHEUS_PORT=9092
- INSPECTIT_EXPORTERS_TRACING_JAEGER_URL=http://jaeger:14268/api/traces
deploy:
resources:
limits:
memory: 1024M
depends_on:
- agent
- ocelot-config-server
- config-server
- discovery-server
entrypoint: ["./dockerize","-wait=tcp://discovery-server:8761","-timeout=120s","--","java", "-javaagent:/agent/inspectit-ocelot-agent.jar", "org.springframework.boot.loader.JarLauncher"]
volumes:
- agent-vol:/agent
ports:
- 8082:8082
- 9092:9092
vets-service:
restart: always
image: inspectit/spring-petclinic-vets-service:${INSPECTIT_PETCLINIC_VERSION}
container_name: vets-service
hostname: vets-service
environment:
- INSPECTIT_SERVICE_NAME=vets-service
- INSPECTIT_CONFIG_HTTP_URL=http://ocelot-config-server:8090/api/v1/agent/configuration
- INSPECTIT_EXPORTERS_METRICS_PROMETHEUS_ENABLED=ENABLED
- INSPECTIT_EXPORTERS_METRICS_PROMETHEUS_PORT=9093
- INSPECTIT_EXPORTERS_TRACING_JAEGER_URL=http://jaeger:14268/api/traces
deploy:
resources:
limits:
memory: 1024M
depends_on:
- agent
- ocelot-config-server
- config-server
- discovery-server
entrypoint: ["./dockerize","-wait=tcp://discovery-server:8761","-timeout=120s","--","java", "-javaagent:/agent/inspectit-ocelot-agent.jar", "org.springframework.boot.loader.JarLauncher"]
volumes:
- agent-vol:/agent
ports:
- 8083:8083
- 9093:9093
api-gateway:
restart: always
image: inspectit/spring-petclinic-api-gateway:${INSPECTIT_PETCLINIC_VERSION}
container_name: api-gateway
hostname: api-gateway
environment:
- INSPECTIT_SERVICE_NAME=api-gateway
- INSPECTIT_CONFIG_HTTP_URL=http://ocelot-config-server:8090/api/v1/agent/configuration
- INSPECTIT_EXPORTERS_METRICS_PROMETHEUS_ENABLED=ENABLED
- INSPECTIT_EXPORTERS_METRICS_PROMETHEUS_PORT=9094
- INSPECTIT_EXPORTERS_TRACING_JAEGER_URL=http://jaeger:14268/api/traces
deploy:
resources:
limits:
memory: 1024M
depends_on:
- agent
- ocelot-config-server
- config-server
- discovery-server
entrypoint: ["./dockerize","-wait=tcp://discovery-server:8761","-timeout=120s","--","java", "-javaagent:/agent/inspectit-ocelot-agent.jar", "org.springframework.boot.loader.JarLauncher"]
volumes:
- agent-vol:/agent
ports:
- 8080:8080
- 9094:9094
# Monitoring Backend
# Load Generator
## Artificial load on Demo
load:
restart: always
image: inspectit/spring-petclinic-load:1.0
container_name: load-generator
hostname: load-generator
# Prometheus
## Time Series Database & Monitoring
prometheus:
restart: always
image: prom/prometheus:v2.29.1
container_name: prometheus
command:
- '--storage.tsdb.retention.time=7d'
- '--config.file=/etc/prometheus/prometheus.yml'
volumes:
- ./prometheus/prometheus.yml:/etc/prometheus/prometheus.yml
ports:
- 9090:9090
# Jaeger
## Collects and visualizes traces
jaeger:
restart: always
image: jaegertracing/all-in-one:1.25.0
container_name: jaeger
ports:
- 16686:16686
# Grafana
## Dashboarding
grafana:
restart: always
image: grafana/grafana:9.0.2
container_name: grafana
environment:
- GF_PANELS_DISABLE_SANITIZE_HTML=TRUE
- GF_SECURITY_ADMIN_PASSWORD=demo
- GF_PATHS_PROVISIONING=/usr/share/grafana/custom/
- GF_INSTALL_PLUGINS=https://github.com/NovatecConsulting/novatec-service-dependency-graph-panel/releases/download/v4.0.2/novatec-sdg-panel.zip;novatec-sdg-panel
volumes:
- ./grafana/provisioning/prometheus:/usr/share/grafana/custom/
- ./grafana/provisioning/home-dashboard/home.json:/usr/share/grafana/public/dashboards/home.json
ports:
- 3000:3000
# Grafana Loki & Promtail
## Make logs available in Grafana
loki:
image: grafana/loki:2.5.0
ports:
- "3100:3100"
command: -config.file=/etc/loki/local-config.yaml
promtail:
image: grafana/promtail:2.5.0
volumes:
- /var/log:/var/log
command: -config.file=/etc/promtail/config.yml
volumes:
agent-vol: