removing HSTS include from location as it is superfluous.
HSTS is defined at the server level and re-adding the host at the location prevents inheritance from the advanced config include. Per the NGINX documentation, "These directives are inherited from the previous configuration level if and only if there are no add_header directives defined on the current level."
This commit is contained in:
parent
c68874743d
commit
2f8097cdd4
2 changed files with 0 additions and 4 deletions
|
|
@ -51,8 +51,6 @@ proxy_http_version 1.1;
|
||||||
|
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% include "_hsts.conf" %}
|
|
||||||
|
|
||||||
{% if allow_websocket_upgrade == 1 or allow_websocket_upgrade == true %}
|
{% if allow_websocket_upgrade == 1 or allow_websocket_upgrade == true %}
|
||||||
proxy_set_header Upgrade $http_upgrade;
|
proxy_set_header Upgrade $http_upgrade;
|
||||||
proxy_set_header Connection $http_connection;
|
proxy_set_header Connection $http_connection;
|
||||||
|
|
|
||||||
|
|
@ -16,8 +16,6 @@ server {
|
||||||
|
|
||||||
{% if use_default_location %}
|
{% if use_default_location %}
|
||||||
location / {
|
location / {
|
||||||
{% include "_hsts.conf" %}
|
|
||||||
|
|
||||||
{% if preserve_path == 1 or preserve_path == true %}
|
{% if preserve_path == 1 or preserve_path == true %}
|
||||||
return {{ forward_http_code }} {{ forward_scheme }}://{{ forward_domain_name }}$request_uri;
|
return {{ forward_http_code }} {{ forward_scheme }}://{{ forward_domain_name }}$request_uri;
|
||||||
{% else %}
|
{% else %}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue