diff --git a/templates/ghost/docker-compose.yml b/templates/ghost/docker-compose.yml index a92f943..a535a10 100644 --- a/templates/ghost/docker-compose.yml +++ b/templates/ghost/docker-compose.yml @@ -34,6 +34,10 @@ services: labels: - "traefik.enable=true" - "traefik.http.routers.ghost.rule=Host(`${SUBDOMAIN}.${DOMAIN}`)" + # R-753: this app reads the LEFTMOST X-Forwarded-For entry, which a stranger writes once traefik keeps the + # tunnel's chain — so its chain is removed here (it then reads traefik's X-Real-Ip or peer; never forgeable). + - "traefik.http.middlewares.ghost-xff.headers.customrequestheaders.X-Forwarded-For=" + - "traefik.http.routers.ghost.middlewares=ghost-xff" - "traefik.http.routers.ghost.entrypoints=websecure" - "traefik.http.routers.ghost.tls=true" - "traefik.http.routers.ghost.tls.certresolver=letsencrypt"