Add support for not passing host header to proxy upstream
This commit is contained in:
@@ -33,6 +33,9 @@
|
||||
{% for header in location.proxy_delete_headers %}
|
||||
header_up -{{ header }}
|
||||
{% endfor %}
|
||||
{% if not location.proxy_pass_host_header %}
|
||||
header_up Host {upstream_hostport}
|
||||
{% endif %}
|
||||
}
|
||||
{% elif location.type == 'redirect' %}
|
||||
redir * {{ location.redirect_target }}{{ '{path}' if location.redirect_preserve_path }}{{ '?{query}' if location.redirect_preserve_query }} {{ location.redirect_type }}
|
||||
|
||||
Reference in New Issue
Block a user