-
Notifications
You must be signed in to change notification settings - Fork 7
/
docker-compose.yml
77 lines (71 loc) · 1.89 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
version: '3'
services:
cadvisor:
image: google/cadvisor:v0.32.0
container_name: cadvisor
restart: always
volumes:
- /:/rootfs:ro
- /var/run:/var/run:rw
- /sys:/sys:ro
- /var/lib/docker/:/var/lib/docker:ro
- /dev/disk/:/dev/disk:ro
command:
- --prometheus_endpoint=/docker-metrics
node-exporter:
image: prom/node-exporter:v0.17.0
container_name: node-exporter
restart: always
volumes:
- /proc:/host/proc:ro
- /sys:/host/sys:ro
- /:/host:ro,rslave
command:
- --web.telemetry-path=/node-metrics
- --path.procfs=/host/proc
- --path.sysfs=/host/sys
- --collector.filesystem.ignored-mount-points=^/(sys|proc|dev|host|etc)($$|/)
prometheus:
image: prom/prometheus:v2.5.0
container_name: prometheus
restart: always
volumes:
- ./prometheus:/etc/prometheus
command:
- --config.file=/etc/prometheus/prometheus.yml
- --storage.tsdb.path=/prometheus
- --web.console.libraries=/usr/share/prometheus/console_libraries
- --web.console.templates=/usr/share/prometheus/consoles
- --web.enable-lifecycle
ports:
- 9090:9090
depends_on:
- cadvisor
- node-exporter
grafana:
image: grafana/grafana:5.3.2
container_name: grafana
restart: always
volumes:
- grafana_data:/var/lib/grafana
- ./grafana/datasources:/etc/grafana/provisioning/datasources
- ./grafana/dashboards:/etc/grafana/provisioning/dashboards
ports:
- 3000:3000
depends_on:
- prometheus
nginx:
image: nginx:1.15.8
container_name: nginx
restart: always
volumes:
- ./nginx/conf.d:/etc/nginx/conf.d
- ./nginx/basic_auth:/etc/nginx/basic_auth
- ./nginx/letsencrypt:/etc/letsencrypt/live
ports:
- 80:80/tcp
- 443:443/tcp
depends_on:
- grafana
volumes:
grafana_data: