roles/nginx: Only use index.php on hosts that need it

Otherwise, use index.html.
This commit is contained in:
Alan Orth 2016-09-13 15:58:40 +03:00
parent bf7accdade
commit 586ad76d6b
Signed by: alanorth
GPG Key ID: 0FB860CC9C45B1B9
1 changed files with 1 additions and 1 deletions

View File

@ -31,7 +31,7 @@ server {
{# will only work if the TLS cert covers the domain + aliases, like example.com and www.example.com #}
server_name {{ domain_name }} {{ domain_aliases }};
index index.php index.html;
index {% if has_wordpress == True or needs_php == True %}index.php{% else %}index.html{% endif %};
access_log /var/log/nginx/{{ domain_name }}-access.log;
error_log /var/log/nginx/{{ domain_name }}-error.log;