add stickiness options

This commit is contained in:
Arne Teuke
2025-02-12 16:21:25 +01:00
parent b1beddf4b3
commit e041552127
2 changed files with 4 additions and 0 deletions

View File

@@ -45,6 +45,7 @@ define cd_haproxy::server::proxy (
$backend_configs = [],
$be_stick_table = '',
$be_stick_on = '',
$be_http_check = '',
) {

View File

@@ -16,6 +16,9 @@ stick-table <%= backend_config['be_stick_table'] %>
<% if backend_config['be_stick_on'] and backend_config['be_stick_on'] != '' -%>
stick on <%= backend_config['be_stick_on'] %>
<% end -%>
<% if backend_config['be_http_check'] and backend_config['be_http_check'] != '' -%>
http-check <%= backend_config['be_http_check'] %>
<% end -%>
<% if backend_config['be_server_name_array'] and !backend_config['be_server_name_array'].empty? -%>
<% backend_config['be_server_name_array'].each do |be_server_name| -%>
server <%= be_server_name %>