Log headers for easier debug and fix timezone

This commit is contained in:
Quentin Duchemin 2022-03-28 11:03:23 +02:00
parent f956b81e24
commit 3a0455e577
No known key found for this signature in database
GPG Key ID: 0547178FEEDE7D6B
2 changed files with 9 additions and 1 deletions

View File

@ -12,11 +12,12 @@ services:
- 80:80
- 443:443
volumes:
- /etc/localtime:/etc/localtime:ro
- /var/run/docker.sock:/var/run/docker.sock
- ./traefik.toml:/traefik.toml
- ./traefik_dynamic.toml:/traefik_dynamic.toml
- /DATA/docker/traefik/certs:/certs
environment:
TZ: Europe/Paris
labels:
traefik.http.routers.traefik-metrics.entrypoints: websecure
traefik.http.routers.traefik-metrics.rule: "Host(`${SERVER_NAME}`) && PathPrefix(`/metrics`)"

View File

@ -33,6 +33,13 @@
level = "INFO"
[accessLog]
format = "json"
[accessLog.fields.headers]
defaultMode = "keep"
# See https://doc.traefik.io/traefik/observability/access-logs/#time-zones
[accessLog.fields.names]
"StartUTC" = "drop"
"ClientUsername" = "drop"
[certificatesResolvers]
[certificatesResolvers.letsencrypt]