forked from sighmon/prometheus-grafana-raspberry-pi
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathdocker-compose.yml
59 lines (59 loc) · 1.79 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
# docker-compose.yml
version: '3'
services:
prometheus:
container_name: prometheus
image: prom/prometheus
volumes:
- ./prometheus/prometheus.yml:/etc/prometheus/prometheus.yml
- ./prometheus/alert.rules:/etc/prometheus/alert.rules
- prometheus_data:/prometheus
command:
- '--config.file=/etc/prometheus/prometheus.yml'
- '--web.console.libraries=/etc/prometheus/console_libraries'
- '--web.console.templates=/etc/prometheus/consoles'
- '--storage.tsdb.retention.time=1y'
- '--web.enable-lifecycle'
ports:
- "9090:9090"
restart: unless-stopped
network_mode: host
node-exporter:
container_name: node-exporter
image: prom/node-exporter-linux-armv7
ports:
- "9100:9100"
command:
- '--web.disable-exporter-metrics'
network_mode: host
restart: on-failure
grafana:
container_name: grafana
image: grafana/grafana:latest
environment:
- GF_SECURITY_ADMIN_PASSWORD=password
- GF_AUTH_ANONYMOUS_ENABLED=true
- GF_AUTH_DISABLE_LOGIN_FORM=false
- GF_ORG_NAME=Main Org.
- GF_ORG_ROLE=viewer
volumes:
- grafana_data:/var/lib/grafana
depends_on:
- prometheus
ports:
- "3000:3000"
network_mode: host
restart: unless-stopped
alertmanager:
container_name: alertmanager
build: ./alertmanager
command:
- '--config.file=/alertmanager.yml'
ports:
- "9093:9093"
network_mode: host
restart: unless-stopped
volumes:
prometheus_data: {}
grafana_data: {}
dhparam_cache: {}