-
Notifications
You must be signed in to change notification settings - Fork 10
Closed
Labels
documentationImprovements or additions to documentationImprovements or additions to documentationenhancementNew feature or requestNew feature or requestgood first issueGood for newcomersGood for newcomers
Description
Problem
When using the sample docker-compose file, cloud scanner metrics scrapped by prometheus are not persisted if the prometheus container is deleted and recreated.
Reason is that we store data directly inside prometheus container, so data lifecycle is the one of the container.
Solution
Use bind mount an external data volume to the prometheus container.
# Create persistent volume for your data
docker volume create prometheus-data
# Start Prometheus container
docker run \
-p 9090:9090 \
-v /path/to/prometheus.yml:/etc/prometheus/prometheus.yml \
-v prometheus-data:/prometheus \
prom/prometheusUpdate the docker-compose file to use this external data volume instead of the default. This is similar to what we do for grafana: declare the volume , and mount it to the container in the docker-compose file.
Describe this in the documentation.
Alternatives
Additional context or elements
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
documentationImprovements or additions to documentationImprovements or additions to documentationenhancementNew feature or requestNew feature or requestgood first issueGood for newcomersGood for newcomers