From 17b49ccc3dd509a0d757b993f7ce0cad43f1ff2d Mon Sep 17 00:00:00 2001 From: Jeremy Lecour Date: Sun, 14 Jun 2020 23:19:40 +0200 Subject: [PATCH] haproxy: simplify syntax fos stats section --- haproxy/templates/haproxy.default.cfg.j2 | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/haproxy/templates/haproxy.default.cfg.j2 b/haproxy/templates/haproxy.default.cfg.j2 index b3a290eb..fb63e1f6 100644 --- a/haproxy/templates/haproxy.default.cfg.j2 +++ b/haproxy/templates/haproxy.default.cfg.j2 @@ -51,12 +51,8 @@ listen stats stats uri / stats show-legends stats show-node + stats admin if { src -f /etc/haproxy/stats_admin_ips } - acl stats_access_ips src -f /etc/haproxy/stats_access_ips - http-request deny if !stats_access_ips - - acl stats_admin_ips src -f /etc/haproxy/stats_admin_ips - stats admin if stats_admin_ips - + http-request deny if !{ src -f /etc/haproxy/stats_access_ips } http-request set-log-level silent {% endif %}