Closed JoJo-Joshua closed 2 years ago
This is a default value in Prometheus so you need to modify the configuration. You can add to the docker-compose file this line:
- '--storage.tsdb.retention.time=90d'
Here's an example:
services:
prometheus:
image: prom/prometheus:v2.0.0
volumes:
- ./prometheus/:/etc/prometheus/
- prometheus_data:/prometheus
command:
- '--config.file=/etc/prometheus/prometheus.yml'
- '--storage.tsdb.path=/prometheus'
- '--storage.tsdb.retention.time=90d'
- '--web.console.libraries=/usr/share/prometheus/console_libraries'
- '--web.console.templates=/usr/share/prometheus/consoles'
ports:
- 9090:9090
links:
- ping:ping
- speedtest:speedtest
networks:
- back-tier
Ah, perfect thank you I have now changed it with me. 🤗🥳
Hey is there any way to change the Prometheus Storage Retention?
If so, how do I do that?