Skip to content
Snippets Groups Projects
Commit 5e708914 authored by jurgenhaas's avatar jurgenhaas
Browse files

Allow haproxy_private to be limited to certain domains only

parent 4809be21
No related branches found
No related tags found
No related merge requests found
......@@ -102,7 +102,7 @@
owner='root'
group='root'
mode='644'
when: haproxy_private is defined and haproxy_private.domain
when: haproxy_private is defined and haproxy_private.domain is defined
notify: "Check HAProxy Config"
- name: "Create config file"
......
......@@ -64,7 +64,7 @@ frontend http_in
{% if haproxy_private.domain is defined %}
acl privatedomain hdr(host) -i -n -f /etc/haproxy/privatelist.domain
{% else %}
acl privatedomain if true
acl privatedomain hdr_cnt(X_Dummy) eq 0
{% endif %}
acl privateip src -f /etc/haproxy/privatelist.ip
acl private_auth http_auth(notprivate) if !privateip
......@@ -191,7 +191,7 @@ frontend https_in_{{ cert.ip }}
{% if haproxy_private.domain is defined %}
acl privatedomain hdr(host) -i -n -f /etc/haproxy/privatelist.domain
{% else %}
acl privatedomain if true
acl privatedomain hdr_cnt(X_Dummy) eq 0
{% endif %}
acl privateip src -f /etc/haproxy/privatelist.ip
acl private_auth http_auth(notprivate) if !privateip
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment