From a2a2943812f5305833fb81c413f425c2ca7b3227 Mon Sep 17 00:00:00 2001 From: Andrea Dell'Amico Date: Wed, 14 Oct 2020 18:20:47 +0200 Subject: [PATCH] Set the haproxy log level --- defaults/main.yml | 1 + templates/haproxy.cfg.j2 | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/defaults/main.yml b/defaults/main.yml index f4ee7db..486bbfa 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -24,3 +24,4 @@ docker_swarm_portainer_service_port: '8000' docker_swarm_keepalived_vrouter_id: 205 docker_swarm_keepalived_floating_ip: '127.0.0.1/8' docker_swarm_keepalived_instance_name: 'VI_HAPROXY_1' +docker_swarm_haproxy_loglevel: '{{ haproxy_loglevel }}' diff --git a/templates/haproxy.cfg.j2 b/templates/haproxy.cfg.j2 index ca7c8f3..07bdc15 100644 --- a/templates/haproxy.cfg.j2 +++ b/templates/haproxy.cfg.j2 @@ -2,7 +2,7 @@ # https://www.haproxy.com/blog/haproxy-on-docker-swarm-load-balancing-and-dns-service-discovery/ # global - log fd@2 local2 + log fd@2 local2 {{ docker_swarm_haproxy_loglevel }} chroot /var/lib/haproxy pidfile /var/run/haproxy.pid maxconn {{ haproxy_maxconns }}