Commit 2dbe480b authored by Thomas Gambier's avatar Thomas Gambier 🚴🏼 Committed by Matevz Golob

[kvm]: fix nat-rule-url for kvm-cluster

parent ab75e9e4
......@@ -23,7 +23,7 @@ md5sum = 26a947c75792072a7b526cb18b617b10
[template-kvm-cluster]
filename = instance-kvm-cluster.cfg.jinja2.in
md5sum = 63fa784d8946d0b6e3fbd6381e1ea9f4
md5sum = 2bbee46d39aec87e92c8462efab292b6
[template-kvm-resilient]
filename = instance-kvm-resilient.cfg.jinja2
......
......@@ -129,7 +129,12 @@ return =
backend-url
{% if str(use_nat).lower() == 'true' -%}
{% for port in nat_rules_list -%}
{{ ' ' }}nat-rule-url-{{ port }}
{% if ':' in port -%}
{% set proto, port = port.split(':') -%}
{% else -%}
{% set proto, port = 'tcp', port -%}
{% endif -%}
{{ ' ' }}nat-rule-url-{{proto}}-{{ port }}
{% endfor -%}
{% endif -%}
{{ ' ' }}monitor-base-url
......
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