net/haproxy: do not enable HSTS unconditionally

This commit is contained in:
Frank Wall
2017-12-08 06:35:37 +01:00
committed by Franco Fichtner
parent e864b05ccb
commit 1f84705450
@@ -606,10 +606,10 @@ frontend {{frontend.name}}
{% if frontend.ssl_cipherList|default("") != "" %}
{% do ssl_options.append('ciphers ' ~ frontend.ssl_cipherList) %}
{% endif %}
{% endif %}
{# # HSTS #}
{% if frontend.ssl_hstsEnabled|default("") == '1' %}
{# # HSTS #}
{% if frontend.ssl_hstsEnabled|default("") == '1' %}
http-response set-header Strict-Transport-Security max-age={{frontend.ssl_hstsMaxAge}}
{% endif %}
{% endif %}
{% endif %}
{# # bind/listen configuration #}