Skip to content

Commit 51c6565

Browse files
committed
DOC-5462 Added Prometheus and Grafana persistent storage setup to docker-compose config file
1 parent 9316fda commit 51c6565

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

content/embeds/rs-prometheus-grafana-quickstart.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,15 +110,26 @@ We recommend running Prometheus in Docker only for development and testing.
110110
- 9090:9090
111111
volumes:
112112
- ./prometheus/prometheus.yml:/etc/prometheus/prometheus.yml
113+
# Persistent storage for Prometheus
114+
- prometheus-data:/prometheus
113115

114116
grafana-ui:
115117
image: grafana/grafana
116118
ports:
117119
- 3000:3000
118120
environment:
119121
- GF_SECURITY_ADMIN_PASSWORD=secret
122+
volumes:
123+
# Persistent storage for Grafana
124+
- grafana-storage:/var/lib/grafana
120125
links:
121126
- prometheus-server:prometheus
127+
128+
# Define Docker-managed volumes for persistent storage
129+
# These volumes are created automatically and persist data between container restarts
130+
volumes:
131+
prometheus-data:
132+
grafana-storage:
122133
```
123134
124135
1. To start the containers, run:

0 commit comments

Comments
 (0)