From b46964dd264bf3c3b2d16e758a925948a00b4229 Mon Sep 17 00:00:00 2001 From: Jacob Cody Wimer Date: Tue, 5 Jul 2016 22:10:16 -0400 Subject: [PATCH] Added cookie support for haproxy --- roles/proxy/templates/haproxy.cfg.j2 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/roles/proxy/templates/haproxy.cfg.j2 b/roles/proxy/templates/haproxy.cfg.j2 index a3905c0..2105b84 100644 --- a/roles/proxy/templates/haproxy.cfg.j2 +++ b/roles/proxy/templates/haproxy.cfg.j2 @@ -38,7 +38,9 @@ frontend www-https backend wrestlingdev redirect scheme https if !{ ssl_fc } balance roundrobin + option redispatch + option httpclose cookie SERVERID insert indirect nocache {% for web_server in groups['web'] %} - server {{ hostvars[web_server]['ansible_eth1']['ipv4']['address'] }} {{ hostvars[web_server]['ansible_eth1']['ipv4']['address'] }}:443 check cookie {{ hostvars[web_server]['ansible_eth1']['ipv4']['address'] }} ssl verify none + server {{ hostvars[web_server]['ansible_eth1']['ipv4']['address'] }} {{ hostvars[web_server]['ansible_eth1']['ipv4']['address'] }}:443 check cookie A ssl verify none {% endfor %}