refactor (service): use more identifiable volume and net name grafana
This commit is contained in:
parent
377c981c81
commit
1f38060fcf
1 changed files with 12 additions and 8 deletions
|
@ -1,6 +1,7 @@
|
||||||
services:
|
services:
|
||||||
prometheus:
|
prometheus:
|
||||||
image: prom/prometheus:latest
|
image: prom/prometheus:latest
|
||||||
|
container_name: prometheus
|
||||||
volumes:
|
volumes:
|
||||||
- ./prometheus/prometheus.yml:/etc/prometheus/prometheus.yml
|
- ./prometheus/prometheus.yml:/etc/prometheus/prometheus.yml
|
||||||
- prometheus_data:/prometheus
|
- prometheus_data:/prometheus
|
||||||
|
@ -8,7 +9,7 @@ services:
|
||||||
|
|
||||||
node-exporter:
|
node-exporter:
|
||||||
image: prom/node-exporter:latest
|
image: prom/node-exporter:latest
|
||||||
restart: unless-stopped
|
container_name: node-exporter
|
||||||
volumes:
|
volumes:
|
||||||
- /proc:/host/proc:ro
|
- /proc:/host/proc:ro
|
||||||
- /sys:/host/sys:ro
|
- /sys:/host/sys:ro
|
||||||
|
@ -17,26 +18,28 @@ services:
|
||||||
- "--path.procfs=/host/proc"
|
- "--path.procfs=/host/proc"
|
||||||
- "--path.rootfs=/rootfs"
|
- "--path.rootfs=/rootfs"
|
||||||
- "--path.sysfs=/host/sys"
|
- "--path.sysfs=/host/sys"
|
||||||
|
restart: unless-stopped
|
||||||
|
|
||||||
loki:
|
loki:
|
||||||
image: grafana/loki:latest
|
image: grafana/loki:latest
|
||||||
restart: unless-stopped
|
container_name: loki
|
||||||
volumes:
|
volumes:
|
||||||
- loki_data:/loki
|
- loki_data:/loki
|
||||||
|
restart: unless-stopped
|
||||||
|
|
||||||
promtail:
|
promtail:
|
||||||
image: grafana/promtail:latest
|
image: grafana/promtail:latest
|
||||||
restart: unless-stopped
|
container_name: promtail
|
||||||
volumes:
|
volumes:
|
||||||
- ./promtail/promtail-config.yml:/etc/promtail/config.yml
|
- ./promtail/promtail-config.yml:/etc/promtail/config.yml
|
||||||
- /var/log:/var/log
|
- /var/log:/var/log
|
||||||
|
restart: unless-stopped
|
||||||
|
|
||||||
grafana:
|
grafana:
|
||||||
image: grafana/grafana:latest
|
image: grafana/grafana:latest
|
||||||
container_name: grafana
|
container_name: grafana
|
||||||
restart: unless-stopped
|
|
||||||
volumes:
|
volumes:
|
||||||
- grafana_data:/var/lib/grafana
|
- data:/var/lib/grafana
|
||||||
environment:
|
environment:
|
||||||
- GF_SECURITY_ADMIN_PASSWORD=${GRAFANA_PASSWORD}
|
- GF_SECURITY_ADMIN_PASSWORD=${GRAFANA_PASSWORD}
|
||||||
- GF_USERS_ALLOW_SIGN_UP=false
|
- GF_USERS_ALLOW_SIGN_UP=false
|
||||||
|
@ -45,15 +48,16 @@ services:
|
||||||
ports:
|
ports:
|
||||||
- "8000:3000"
|
- "8000:3000"
|
||||||
networks:
|
networks:
|
||||||
- default
|
- internal
|
||||||
- web
|
- web
|
||||||
|
restart: unless-stopped
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
|
data:
|
||||||
prometheus_data:
|
prometheus_data:
|
||||||
loki_data:
|
loki_data:
|
||||||
grafana_data:
|
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
default:
|
internal:
|
||||||
web:
|
web:
|
||||||
external: true
|
external: true
|
||||||
|
|
Loading…
Add table
Reference in a new issue