Skip to content

Retention period not being honoured #114

@aryan-nvd

Description

@aryan-nvd

Bug Description

With the following docker-compose configuration
services:
prometheus:
image: ubuntu/prometheus
container_name: prometheus
restart: unless-stopped
volumes:
# - ~/data/prometheus/promo-config:/etc/prometheus
- ./prometheus-config:/etc/prometheus
- ./rules.yml:/etc/prometheus/rules.yml
- ~/data/prometheus/data:/prometheus
networks:
- localprom
ports:
- 9090:9090
command:
- "/bin/prometheus"
- "--config.file=/etc/prometheus/prometheus.yml"
- "--storage.tsdb.path=/prometheus"
- "--storage.tsdb.retention.time=60d" # Retention period of 60 days
user: "1000:1000"

the retention value of 60d is never retained, and the prometheus instance always restarts at 15d

I have tried many things including the wonderful ChaGPT/Gemini and no avail.

except it state that I should be using the prom/prometheus, and that this image might not honour the variable (which I doubt)

To Reproduce

docker compose start -d

view prometheus status screen

Image
always has Storage retention 15d

Environment

EC2 running AWS Linux
with
Docker version 25.0.8, build 0bab007

Relevant log output

Storage retention	15d

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions