docs: update traefik example and add note about forwarded headers (#784)

This commit is contained in:
Caleb Doxsey 2020-05-26 18:14:11 -06:00 committed by GitHub
parent 268a7067c1
commit f03f57980c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -543,15 +543,22 @@ spec:
#### Traefik docker-compose
If the `forward_auth_url` is also handled by Traefik, you will need to configure Traefik to trust the `X-Forwarded-*`
headers as described in [the documentation](https://docs.traefik.io/v2.2/routing/entrypoints/#forwarded-headers).
```yml
version: "3"
services:
traefik:
# The official v2.0 Traefik docker image
image: traefik:v2.0
# The official v2.2 Traefik docker image
image: traefik:v2.2
# Enables the web UI and tells Traefik to listen to docker
command: --api.insecure=true --providers.docker
command:
- "--api.insecure=true"
- "--providers.docker=true"
- "--entrypoints.web.address=:80"
- "--entrypoints.web.forwardedheaders.insecure=true"
ports:
# The HTTP port
- "80:80"