mirror of
https://github.com/netbirdio/plugins.git
synced 2026-05-22 18:44:07 -07:00
net/haproxy: support rise/fall parameters in health checks
This commit is contained in:
@@ -77,6 +77,20 @@
|
||||
<type>checkbox</type>
|
||||
<help><![CDATA[Enable to log health check status updates.]]></help>
|
||||
</field>
|
||||
<field>
|
||||
<id>backend.healthCheckFall</id>
|
||||
<label>Unhealthy Threshold</label>
|
||||
<type>text</type>
|
||||
<help><![CDATA[The number of consecutive unsuccessful health checks before a server is considered as unavailable.]]></help>
|
||||
<advanced>true</advanced>
|
||||
</field>
|
||||
<field>
|
||||
<id>backend.healthCheckRise</id>
|
||||
<label>Healthy Threshold</label>
|
||||
<type>text</type>
|
||||
<help><![CDATA[The number of consecutive successful health checks before a server is considered as available.]]></help>
|
||||
<advanced>true</advanced>
|
||||
</field>
|
||||
<field>
|
||||
<label>Stick-table persistence</label>
|
||||
<type>header</type>
|
||||
|
||||
@@ -664,6 +664,18 @@
|
||||
<default>0</default>
|
||||
<Required>N</Required>
|
||||
</healthCheckLogStatus>
|
||||
<healthCheckFall type="IntegerField">
|
||||
<MinimumValue>1</MinimumValue>
|
||||
<MaximumValue>100</MaximumValue>
|
||||
<ValidationMessage>Please specify a value between 1 and 100.</ValidationMessage>
|
||||
<Required>N</Required>
|
||||
</healthCheckFall>
|
||||
<healthCheckRise type="IntegerField">
|
||||
<MinimumValue>1</MinimumValue>
|
||||
<MaximumValue>100</MaximumValue>
|
||||
<ValidationMessage>Please specify a value between 1 and 100.</ValidationMessage>
|
||||
<Required>N</Required>
|
||||
</healthCheckRise>
|
||||
<stickiness_pattern type="OptionField">
|
||||
<Required>N</Required>
|
||||
<default>sourceipv4</default>
|
||||
|
||||
@@ -1012,6 +1012,14 @@ backend {{backend.name}}
|
||||
{% if server_data.checkDownInterval|default("") != "" %}
|
||||
{% do server_options.append('downinter ' ~ server_data.checkDownInterval) %}
|
||||
{% endif %}
|
||||
{# # unhealthy threshold #}
|
||||
{% if backend.healthCheckFall|default("") != "" %}
|
||||
{% do server_options.append('fall ' ~ backend.healthCheckFall) %}
|
||||
{% endif %}
|
||||
{# # healthy threshold #}
|
||||
{% if backend.healthCheckRise|default("") != "" %}
|
||||
{% do server_options.append('rise ' ~ backend.healthCheckRise) %}
|
||||
{% endif %}
|
||||
{# # use a different port for health check #}
|
||||
{% if healthcheck_data.checkport|default("") != "" %}
|
||||
{# # prefer port from health check template #}
|
||||
|
||||
Reference in New Issue
Block a user