roles/nginx: Fix variable check in HTTPS template
Don't assume the variables for TLS certs exist.
This commit is contained in:
parent
24e54c0580
commit
78dbdae783
@ -4,7 +4,7 @@
|
||||
{% set enable_hsts = item.enable_hsts | default("no") %}
|
||||
|
||||
{# first, check if the current vhost has a custom cert (perhaps self-signed) #}
|
||||
{% if item.tls_certificate_path and item.tls_key_path %}
|
||||
{% if item.tls_certificate_path is defined and item.tls_key_path is defined %}
|
||||
|
||||
# concatenated key + cert
|
||||
# See: http://nginx.org/en/docs/http/configuring_https_servers.html
|
||||
|
Loading…
Reference in New Issue
Block a user