This commit is contained in:
parent
b108a0b82a
commit
0b43023eda
@ -13,6 +13,19 @@ server {
|
|||||||
|
|
||||||
index index.php index.html;
|
index index.php index.html;
|
||||||
|
|
||||||
|
{%- if internal and not auth %}
|
||||||
|
if ($allow = false) {
|
||||||
|
return 403;
|
||||||
|
}
|
||||||
|
{%- endif %}
|
||||||
|
if ($allow = true) {
|
||||||
|
set $auth "off";
|
||||||
|
}
|
||||||
|
{%- if auth %}
|
||||||
|
auth_basic $auth;
|
||||||
|
auth_basic_user_file {{ config_dir }}/auth/htpasswd;
|
||||||
|
{%- endif %}
|
||||||
|
|
||||||
{%- for key,value in headers.items() %}
|
{%- for key,value in headers.items() %}
|
||||||
add_header {{ key }} "{{ value }}";
|
add_header {{ key }} "{{ value }}";
|
||||||
{%- endfor %}
|
{%- endfor %}
|
||||||
|
Loading…
Reference in New Issue
Block a user