From 0e54ff0eaad055f25b4472f126188c4b51db9080 Mon Sep 17 00:00:00 2001 From: Juan Ferrer Toribio Date: Mon, 22 Nov 2021 19:02:33 +0100 Subject: [PATCH] rproxy config template updated --- rproxy.handlebars | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/rproxy.handlebars b/rproxy.handlebars index 239173d..e89f425 100644 --- a/rproxy.handlebars +++ b/rproxy.handlebars @@ -6,36 +6,36 @@ frontend http bind :443 ssl crt /etc/haproxy/cert.pem option forwardfor - # XXX: To test configuration + # Test configuration #http-request set-header Host domain.local # Set environment - http-request set-var(req.backend) req.hdr(host),map_str(/etc/haproxy/maps/host.map) http-request set-var(req.backend) base,map_beg(/etc/haproxy/maps/base.map) http-request set-var(req.acl) src,map_ip(/etc/haproxy/maps/acl.map) http-request set-var(req.zone) var(req.backend),map_str(/etc/haproxy/maps/zone.map) http-request set-var(req.aclZone) var(req.acl),concat(/,req.zone) - # XXX: Debugging - #log-format "%[var(txn.test)]" + # Debug + #http-request set-var(txn.debug) var(req.varName) + #log-format "%[var(txn.debug)]" # ACL check - acl allow var(req.aclZone) -f /etc/haproxy/maps/access.map http-request deny if !allow # HTTPS redirect - acl https var(req.backend) -f /etc/haproxy/maps/https.map http-request add-header X-Forwarded-Proto https if { ssl_fc } redirect scheme https if !{ ssl_fc } https # Backend - default_backend not-found use_backend %[var(req.backend)] +backend not-found + http-request deny deny_status 400 + # Auto-generated backends {{#each services}}