If Traefik is behind a Cloudflare/AWS Cloudfront Proxy/Tunnel, it won't be able to get the real IP from the external client as well as other information.
Processed Headers:
Supported configurations per body
Setting | Allowed values | Required | Description |
---|---|---|---|
provider | string | yes | auto, cloudfront, cloudflare |
trustip->{provider} | []string | No | IP or IP range to trust |
disableDefault | bool | Yes | Disable the built in list of CloudFlare IPs/Servers |
experimental:plugins:traefikdisolver:modulename: github.com/kyaxcorp/traefikdisolverversion: v1.0.9
http:middlewares:traefikdisolver-auto:plugin:traefikdisolver:provider: autodisableDefault: truetrustip: # Trust IPS not required if disableDefault is false - we will allocate Cloud Flare IPs automaticallycloudflare:- "0.0.0.0/0"- "::/0"cloudfront:- "0.0.0.0/0"- "::/0"traefikdisolver-cloudfront:plugin:traefikdisolver:provider: cloudfrontdisableDefault: truetrustip: # Trust IPS not required if disableDefault is false - we will allocate Cloud Flare IPs automaticallycloudfront:- "0.0.0.0/0"- "::/0"traefikdisolver-cloudflare:plugin:traefikdisolver:provider: cloudflaredisableDefault: truetrustip: # Trust IPS not required if disableDefault is false - we will allocate Cloud Flare IPs automaticallycloudflare:- "0.0.0.0/0"- "::/0"routers:my-router-auto:rule: PathPrefix(`/`) && (Host(`cloudfront.example.com`) || Host(`cloudflare.example.com`))service: service-whoamientryPoints:- httpmiddlewares:- traefikdisolver-cloudfrontmy-router-cloudfront:rule: PathPrefix(`/`) && Host(`cloudfront.example.com`)service: service-whoamientryPoints:- httpmiddlewares:- traefikdisolver-cloudfrontmy-router-cloudflare:rule: PathPrefix(`/`) && Host(`cloudflare.example.com`)service: service-whoamientryPoints:- httpmiddlewares:- traefikdisolver-cloudflareservices:service-whoami:loadBalancer:servers:- url: http://127.0.0.1:5000