Skip to content

Commit

Permalink
don't loose data of docker containers
Browse files Browse the repository at this point in the history
  • Loading branch information
sstrigler committed Nov 4, 2024
1 parent 25d8f4f commit 769dbf0
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions mod_prometheus/example/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,25 @@ version: '3.7'
services:

prometheus:
network_mode: "host"
image: docker.io/prom/prometheus
container_name: prometheus
ports:
- "9090:9090"
volumes:
- prometheus-data:/prometheus
- ./prometheus.yml:/etc/prometheus/prometheus.yml
restart: always

grafana:
network_mode: "host"
image: docker.io/grafana/grafana-enterprise
container_name: grafana
ports:
- "3000:3000"
volumes:
- grafana-data:/var/lib/grafana
- ./grafana_defaults.ini:/usr/share/grafana/conf/defaults.ini
restart: always

volumes:
prometheus-data:
grafana-data:

0 comments on commit 769dbf0

Please sign in to comment.