roles/nginx: Allow sites to override the root
This commit is contained in:
parent
e1b412bfff
commit
73d6abd15f
@ -26,7 +26,12 @@ server {
|
||||
listen 443 ssl http2;
|
||||
listen [::]:443 ssl http2;
|
||||
|
||||
{# Allow sites to override the nginx document root #}
|
||||
{% if item.document_root is defined %}
|
||||
root {{ item.document_root }};
|
||||
{% else %}
|
||||
root {{ nginx_root_prefix }}/{{ domain_name }};
|
||||
{% endif %}
|
||||
|
||||
{# will only work if the TLS cert covers the domain + aliases, like example.com and www.example.com #}
|
||||
server_name {{ domain_name }} {{ domain_aliases }};
|
||||
|
Loading…
Reference in New Issue
Block a user