Additional acme-challenge fix
For the case where HTTPS_METHOD=noredirect.
This commit is contained in:
parent
b73ffd88ab
commit
f1baeda5d4
1 changed files with 10 additions and 0 deletions
10
nginx.tmpl
10
nginx.tmpl
|
|
@ -355,6 +355,16 @@ server {
|
||||||
{{ if eq $network_tag "internal" }}
|
{{ if eq $network_tag "internal" }}
|
||||||
# Only allow traffic from internal clients
|
# Only allow traffic from internal clients
|
||||||
include /etc/nginx/network_internal.conf;
|
include /etc/nginx/network_internal.conf;
|
||||||
|
{{ else }}
|
||||||
|
{{ if (eq $https_method "noredirect") }}
|
||||||
|
location /.well-known/acme-challenge/ {
|
||||||
|
auth_basic off;
|
||||||
|
allow all;
|
||||||
|
root /usr/share/nginx/html;
|
||||||
|
try_files $uri =404;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
{{ end }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
{{ if (exists (printf "/etc/nginx/vhost.d/%s" $host)) }}
|
{{ if (exists (printf "/etc/nginx/vhost.d/%s" $host)) }}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue