-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
74 lines (67 loc) · 1.56 KB
/
Copy pathdocker-compose.yml
File metadata and controls
74 lines (67 loc) · 1.56 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
version: '3.8'
services:
# 1. Your Spring Boot Application
my-spring-app:
build: .
container_name: pokesheets
ports:
- "8080:8080"
restart: always
volumes:
- ${GOOGLE_APPLICATION_CREDENTIALS}:/app/credentials.json
environment:
- GOOGLE_APPLICATION_CREDENTIALS=/app/credentials.json
networks:
- monitoring
# 2. Prometheus Service
prometheus:
image: prom/prometheus:latest
container_name: prometheus
ports:
- "9090:9090"
volumes:
- ./prometheus/prometheus.yml:/etc/prometheus/prometheus.yml
command:
- '--config.file=/etc/prometheus/prometheus.yml'
restart: always
networks:
- monitoring
# 3. Grafana Service
grafana:
image: grafana/grafana-oss:latest
container_name: grafana
ports:
- "3000:3000"
volumes:
- grafana-data:/var/lib/grafana
restart: always
networks:
- monitoring
# 4. Loki Service
loki:
image: grafana/loki:3.3.2
container_name: loki
ports:
- "3100:3100"
command: -config.file=/etc/loki/local-config.yaml
volumes:
- ./loki-config.yaml:/etc/loki/local-config.yaml
restart: always
networks:
- monitoring
# 5. Promtail Service
promtail:
image: grafana/promtail:3.3.2
container_name: promtail
volumes:
- ./promtail-config.yaml:/etc/promtail/config.yaml
- /var/log:/var/log
command: -config.file=/etc/promtail/config.yaml
restart: always
networks:
- monitoring
volumes:
grafana-data:
networks:
monitoring:
driver: bridge