-
Notifications
You must be signed in to change notification settings - Fork 12
/
docker-compose.localhost.yml
88 lines (80 loc) · 2.18 KB
/
docker-compose.localhost.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
version: '3.5'
services:
cadvisor:
image: google/cadvisor
volumes:
- /:/rootfs:ro
- /var/run:/var/run:rw
- /sys:/sys:ro
- /var/lib/docker:/var/lib/docker:ro
networks:
- private
ports:
- 8080:8080
node-exporter:
image: prom/node-exporter
volumes:
- /proc:/host/proc:ro
- /sys:/host/sys:ro
- /:/rootfs:ro
ports:
- 9100:9100
command:
- '--path.procfs=/host/proc'
- '--path.sysfs=/host/sys'
- '--collector.filesystem.ignored-mount-points'
- "^/(sys|proc|dev|host|etc|rootfs/var/lib/docker/containers|rootfs/var/lib/docker/overlay2|rootfs/run/docker/netns|rootfs/var/lib/docker/aufs)($$|/)"
networks:
- private
blackbox-exporter:
image: prom/blackbox-exporter:v0.12.0
networks:
- private
alertmanager:
image: prom/alertmanager
command:
- '--config.file=/etc/alertmanager/config.yml'
- '--storage.path=/alertmanager'
volumes:
- ./alertmanager/configs/alertmanager.yml:/etc/alertmanager/config.yml
- alertmanager:/alertmanager
networks:
- private
ports:
- 9093:9093
prometheus:
image: prom/prometheus
user: root
volumes:
- ./prometheus/configs/prometheus-localhost.yml:/etc/prometheus/prometheus.yml
- ./prometheus/rules/alert.rules:/etc/prometheus/alert.rules
- promdata:/prometheus
command:
- '--config.file=/etc/prometheus/prometheus.yml'
- '--storage.tsdb.path=/prometheus'
- '--web.console.libraries=/etc/prometheus/console_libraries'
- '--web.console.templates=/etc/prometheus/consoles'
networks:
- private
ports:
- 9090:9090
grafana:
image: grafana/grafana
volumes:
- grafanadata:/var/lib/grafana
environment:
- GF_SERVER_ROOT_URL=http://grafana.${DOMAIN:-localdns.xyz}
- GF_SECURITY_ADMIN_USER=${GRAFANA_USER:-admin}
- GF_SECURITY_ADMIN_PASSWORD=${GRAFANA_PASSWORD:-admin}
- GF_USERS_ALLOW_SIGN_UP=false
- PROMETHEUS_ENDPOINT=http://prometheus:9090
networks:
- private
ports:
- 3000:3000
networks:
private: {}
volumes:
promdata: {}
grafanadata: {}
alertmanager: {}