mirror of
https://github.com/geerlingguy/ansible-role-nginx.git
synced 2024-10-01 04:37:26 +02:00
make the "server_name" directive optional
This commit is contained in:
parent
e818255465
commit
102949fcb8
@ -1,7 +1,10 @@
|
||||
{% for vhost in nginx_vhosts %}
|
||||
server {
|
||||
listen {{ vhost.listen | default('80 default_server') }};
|
||||
|
||||
{% if vhost.server_name is defined %}
|
||||
server_name {{ vhost.server_name }};
|
||||
{% endif %}
|
||||
|
||||
{% if vhost.root is defined %}
|
||||
root {{ vhost.root }};
|
||||
|
Loading…
Reference in New Issue
Block a user