As the title says, I'm looking for the practical difference (and potential pitfalls) of using $http_host
instead of the $host
variable in the proxy_set_header
settings in nginx
Of course I have already read the answer to this question What's the difference of $host and $http_host in Nginx. But apart from $host
removing the port and making lower case, that doesn't really explain in what scenarios that would affect my application, like when will the "HTTP_HOST is absent or is an empty value"? Is it when the user are using an older browser or when he/she passes through another proxy at the way?
(I'm using nginx to route traffic to a python flask backend application (also using flask-socket.io)