write access list to proxy host config

This commit is contained in:
Kyle Klaus
2020-04-13 23:31:44 -07:00
parent e2ee2cbf2d
commit f5ee91aeb3
5 changed files with 29 additions and 11 deletions

View File

@ -21,11 +21,21 @@ server {
{% if use_default_location %}
location / {
{%- if access_list_id > 0 -%}
# Access List
{% if access_list_id > 0 %}
# Authorization
auth_basic "Authorization required";
auth_basic_user_file /data/access/{{ access_list_id }};
{%- endif %}
# Access Rules
{% for client in access_list.clients %}
{{- client.rule -}};
{% endfor %}deny all;
# Access checks must...
{{ access_list.satisfy }};
{% endif %}
{% include "_forced_ssl.conf" %}
{% include "_hsts.conf" %}