diff --git a/defaults/main.yml b/defaults/main.yml index 87006c0..af3c2bc 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -56,6 +56,7 @@ haproxy_global_logs: haproxy_global_tunes: - tune.ssl.default-dh-param: 2048 # haproxy_global_server_state_base: current +# haproxy_global_server_state_file: /tmp/server_state # haproxy_global_toggles: [] # Default diff --git a/templates/etc/haproxy/haproxy-global.cfg.j2 b/templates/etc/haproxy/haproxy-global.cfg.j2 index 67f930c..b3df6b6 100644 --- a/templates/etc/haproxy/haproxy-global.cfg.j2 +++ b/templates/etc/haproxy/haproxy-global.cfg.j2 @@ -79,6 +79,9 @@ global {% if haproxy_global_server_state_base is defined %} server-state-base {{ haproxy_global_server_state_base }} {% endif %} +{% if haproxy_global_server_state_file is defined %} + server-state-file {{ haproxy_global_server_state_file }} +{% endif %} {% if haproxy_global_toggles is defined and haproxy_global_toggles | length %} {% for toggle in haproxy_global_toggles %} {{ toggle }}