monitoring

This commit is contained in:
xcad2k
2021-09-17 14:12:39 +02:00
parent 891907bd41
commit af765e7b93
11 changed files with 112 additions and 1 deletions

View File

@@ -0,0 +1,54 @@
---
version: '3'
volumes:
prometheus-data:
driver: local
grafana-data:
driver: local
services:
prometheus:
image: prom/prometheus:latest
container_name: prometheus
ports:
- "9090:9090"
volumes:
- /etc/prometheus:/config
- prometheus-data:/prometheus
restart: unless-stopped
command:
- "--config.file=/config/prometheus.yml"
grafana:
image: grafana/grafana:latest
container_name: grafana
ports:
- "3000:3000"
volumes:
- grafana-data:/var/lib/grafana
restart: unless-stopped
cadvisor:
image: google/cadvisor:latest
container_name: cadvisor
# ports:
# - "8080:8080"
volumes:
- /:/rootfs:ro
- /var/run:/var/run:ro
- /sys:/sys:ro
- /var/lib/docker/:/var/lib/docker:ro
- /dev/disk/:/dev/disk:ro
devices:
- /dev/kmsg
node_exporter:
image: quay.io/prometheus/node-exporter:latest
container_name: node_exporter
command:
- '--path.rootfs=/host'
pid: host
restart: unless-stopped
volumes:
- '/:/host:ro,rslave'