Fix missing 'option tcp-check' for TCP health-check
Change-Id: I32ebbde30bf6995cfd56602064fb6a6bbf0c1ab5
diff --git a/haproxy/files/haproxy.cfg b/haproxy/files/haproxy.cfg
index 5926ace..f7c976d 100644
--- a/haproxy/files/haproxy.cfg
+++ b/haproxy/files/haproxy.cfg
@@ -172,6 +172,9 @@
{%- if type == 'http' and 'httpchk' not in listen.get('options', []) %}
option httpchk
{%- endif %}
+ {%- if type == 'tcp' and 'tcp-check' not in listen.get('options', []) %}
+ option tcp-check
+ {%- endif %}
{%- for option in checks.get('options', []) %}
{{ type }}-check {{ option }}
{%- endfor %}