fix: auth env vars shuffle
This commit is contained in:
parent
897bf69b8c
commit
fd6857b7e4
@ -6,6 +6,7 @@ services:
|
|||||||
environment:
|
environment:
|
||||||
- AUTH_ENABLED
|
- AUTH_ENABLED
|
||||||
- AUTH_USERNAME
|
- AUTH_USERNAME
|
||||||
|
- DOMAIN
|
||||||
configs:
|
configs:
|
||||||
- source: htpasswd_conf
|
- source: htpasswd_conf
|
||||||
target: /etc/nginx/.htpasswd
|
target: /etc/nginx/.htpasswd
|
||||||
|
@ -6,7 +6,6 @@ services:
|
|||||||
image: nginx:1.25.3-alpine
|
image: nginx:1.25.3-alpine
|
||||||
environment:
|
environment:
|
||||||
- DOMAIN
|
- DOMAIN
|
||||||
- HTTP_BASIC_AUTH_ENABLED
|
|
||||||
configs:
|
configs:
|
||||||
- source: nginx_conf
|
- source: nginx_conf
|
||||||
target: /etc/nginx/conf.d/default.conf
|
target: /etc/nginx/conf.d/default.conf
|
||||||
|
@ -9,7 +9,7 @@ server {
|
|||||||
}
|
}
|
||||||
|
|
||||||
location /deploy {
|
location /deploy {
|
||||||
{{ if eq (env "HTTP_BASIC_AUTH_ENABLED") "1" }}
|
{{ if eq (env "AUTH_ENABLED") "1" }}
|
||||||
auth_basic "Administrator’s Area";
|
auth_basic "Administrator’s Area";
|
||||||
auth_basic_user_file /etc/nginx/.htpasswd;
|
auth_basic_user_file /etc/nginx/.htpasswd;
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user