Hello,
I am trying to proxy an external service via Traefik. I somehow can't get it to correctly set the host header so that the target service matches it to the right hostname.
Below an example with Google that demonstrates it (returns 404 because the host header isn't set to google.com). When turning on debugging the Host stays localhost/null.
What am I missing?
[http]
[http.routers]
[http.routers.google]
rule = "PathPrefix(`/`)"
middleware = ["hostHeader"]
service = "google"
[http.middlewares]
[http.middlewares.hostHeader.headers]
[http.middlewares.hostHeader.headers.customRequestHeaders]
Host = "google.com"
[http.services]
[http.services.google.loadBalancer]
[[http.services.google.loadBalancer.servers]]
url = "https://google.com"
Thanks,
Elmar