Fix bugs in config file from refactor

This commit is contained in:
CoreOS Admin 2015-08-29 18:38:43 -06:00
parent 5089bf77dd
commit ae0da36d75

View file

@ -125,8 +125,8 @@ server {
{{ if (exists (printf "/etc/nginx/vhost.d/%s" $host)) }}
include {{ printf "/etc/nginx/vhost.d/%s" $host }};
{{ else if (exists /etc/vhost.d/default) }}
include /etc/nginx/vhost.d/default
{{ else if (exists "/etc/vhost.d/default") }}
include /etc/nginx/vhost.d/default;
{{ end }}
location / {
@ -136,9 +136,9 @@ server {
auth_basic_user_file {{ (printf "/etc/nginx/htpasswd/%s" $host) }};
{{ end }}
{{ if (exists (printf "/etc/nginx/vhost.d/%s_location" $host)) }}
include {{ printf "/etc/nginx/vhost.d/%s_location"}}
{{ else if (exists /etc/vhost.d/default_location) }}
include /etc/nginx/vhost.d/default_location
include {{ printf "/etc/nginx/vhost.d/%s_location" $host}};
{{ else if (exists "/etc/vhost.d/default_location") }}
include /etc/nginx/vhost.d/default_location;
{{ end }}
}
}
@ -150,8 +150,8 @@ server {
{{ if (exists (printf "/etc/nginx/vhost.d/%s" $host)) }}
include {{ printf "/etc/nginx/vhost.d/%s" $host }};
{{ else if (exists /etc/vhost.d/default) }}
include /etc/nginx/vhost.d/default
{{ else if (exists "/etc/vhost.d/default") }}
include /etc/nginx/vhost.d/default;
{{ end }}
location / {
@ -161,9 +161,9 @@ server {
auth_basic_user_file {{ (printf "/etc/nginx/htpasswd/%s" $host) }};
{{ end }}
{{ if (exists (printf "/etc/nginx/vhost.d/%s_location" $host)) }}
include {{ printf "/etc/nginx/vhost.d/%s_location"}}
{{ else if (exists /etc/vhost.d/default_location) }}
include /etc/nginx/vhost.d/default_location
include {{ printf "/etc/nginx/vhost.d/%s_location" $host}};
{{ else if (exists "/etc/vhost.d/default_location") }}
include /etc/nginx/vhost.d/default_location;
{{ end }}
}
}