simplifie la conf prometheus

This commit is contained in:
nom 2025-05-02 11:47:09 +02:00
parent 87b007d4b9
commit 8d0caad3c7

View File

@ -10,24 +10,24 @@ services:
- /etc/timezone:/etc/timezone:ro - /etc/timezone:/etc/timezone:ro
- /etc/localtime:/etc/localtime:ro - /etc/localtime:/etc/localtime:ro
command: command:
- "--web.route-prefix=/" # - "--web.route-prefix=/"
- "--web.external-url=https://prometheus.${domain}" # - "--web.external-url=https://prometheus.${domain}"
- "--config.file=/etc/prometheus/prometheus.yml" - "--config.file=/etc/prometheus/prometheus.yml"
- "--storage.tsdb.path=/prometheus" - "--storage.tsdb.path=/prometheus"
- "--web.console.libraries=/usr/share/prometheus/console_libraries" - "--web.console.libraries=/usr/share/prometheus/console_libraries"
- "--web.console.templates=/usr/share/prometheus/consoles" - "--web.console.templates=/usr/share/prometheus/consoles"
networks: networks:
- traefikNet - traefikNet
labels: # labels:
- "traefik.enable=true" # - "traefik.enable=true"
- "traefik.http.routers.prometheus-secure.entrypoints=websecure" # - "traefik.http.routers.prometheus-secure.entrypoints=websecure"
- "traefik.http.middlewares.prometheus-stripprefix.stripprefix.prefixes=/prometheus" # - "traefik.http.middlewares.prometheus-stripprefix.stripprefix.prefixes=/prometheus"
- "traefik.http.routers.prometheus-secure.rule=Host(`prometheus.${domain}`)" # - "traefik.http.routers.prometheus-secure.rule=Host(`prometheus.${domain}`)"
# - "traefik.http.routers.prometheus-secure.tls=true" # # - "traefik.http.routers.prometheus-secure.tls=true"
- "traefik.http.routers.prometheus-secure.middlewares=prometheus-stripprefix,test-adminiallowlist@file,traefik-auth" # - "traefik.http.routers.prometheus-secure.middlewares=prometheus-stripprefix,test-adminiallowlist@file,traefik-auth"
- "traefik.http.routers.prometheus-secure.service=prometheus" # - "traefik.http.routers.prometheus-secure.service=prometheus"
- "traefik.http.services.prometheus.loadbalancer.server.port=9090" # - "traefik.http.services.prometheus.loadbalancer.server.port=9090"
- "traefik.docker.network=traefikNet" # - "traefik.docker.network=traefikNet"
grafana: grafana:
image: grafana/grafana:11.6.0 image: grafana/grafana:11.6.0