Commit 75bdc645 authored by Cédric Le Ninivin's avatar Cédric Le Ninivin

erp5_cluster: leave ERP5 set the haproxy cookie

erp5-cluster: haproxy, move generic configuration into default section
parent 9e5385bc
...@@ -346,7 +346,7 @@ md5sum = dedfe759c3421e0186703fe1257bae8f ...@@ -346,7 +346,7 @@ md5sum = dedfe759c3421e0186703fe1257bae8f
[template-haproxy-cfg] [template-haproxy-cfg]
< = download-base < = download-base
filename = haproxy.cfg.in filename = haproxy.cfg.in
md5sum = d27fe9218cb737d8a76ba5df4740f947 md5sum = 7f13123698afe017dfcde9de6beea0f5
[bt5-repository] [bt5-repository]
# Format: # Format:
......
...@@ -11,7 +11,8 @@ defaults ...@@ -11,7 +11,8 @@ defaults
retries 1 retries 1
option redispatch option redispatch
maxconn 2000 maxconn 2000
cookie SERVERID insert nocache cookie SERVERID rewrite
http-send-name-header X-Balancer-Current-Server
balance roundrobin balance roundrobin
stats uri /haproxy stats uri /haproxy
stats realm Global\ statistics stats realm Global\ statistics
...@@ -37,6 +38,7 @@ defaults ...@@ -37,6 +38,7 @@ defaults
{% for name, (port, backend_list) in parameter_dict['backend-dict'].items() -%} {% for name, (port, backend_list) in parameter_dict['backend-dict'].items() -%}
listen {{ name }} {{ parameter_dict['ip'] }}:{{ port }} listen {{ name }} {{ parameter_dict['ip'] }}:{{ port }}
http-request set-header X-Balancer-Current-Cookie SERVERID
{% set has_webdav = [] -%} {% set has_webdav = [] -%}
{% for address, connection_count, webdav in backend_list -%} {% for address, connection_count, webdav in backend_list -%}
{% if webdav %}{% do has_webdav.append(None) %}{% endif -%} {% if webdav %}{% do has_webdav.append(None) %}{% endif -%}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment