MT#61304 Handle conflicting Prosody and HAProxy ports

These share the same ports depending on the role of the current node, so
to avoid emitting the same duplicate port entries we should turn these
into cascading if/elif.

This is being detected by new goss versions from Debian trixie as
errors, and causing the entire ngcp-system-tests run to fail.

Change-Id: I2898f623e87867a03ef6cfb728a90631f53ffae7
mr13.1
Guillem Jover 6 months ago
parent 5a3c4f69a4
commit 32d134f452

@ -124,26 +124,6 @@ port:
listening: {{.Vars.NODE_ACTIVE}}
ip: ["[% sip_ext_ips.0 %]"]
# HAProxy: Prosody (xmpp-client)
tcp:5222:
listening: [% haproxy.enable == 'yes' ? 'true' : 'false' %]
ip: ["[% sip_ext_ips.0 %]"]
# HAProxy: Prosody (xmpp-server)
tcp:5269:
listening: [% haproxy.enable == 'yes' ? 'true' : 'false' %]
ip: ["[% sip_ext_ips.0 %]"]
# HAProxy: Prosody (http)
tcp:5281:
listening: [% haproxy.enable == 'yes' ? 'true' : 'false' %]
ip: ["[% sip_ext_ips.0 %]"]
# HAProxy admin
tcp:8080:
listening: [% haproxy.enable == 'yes' && haproxy.admin == 'yes' ? 'true' : 'false' %]
ip: ["[% sip_ext_ips.0 %]"]
[% END -%]
[% IF is_proxy -%]
# Kamailio proxy
@ -151,31 +131,68 @@ port:
listening: {{.Vars.NODE_ACTIVE}}
ip: ["[% sip_int_ips.0 %]"]
[% END -%]
[% IF is_proxy -%]
# Prosody (xmpp-client)
tcp:5222:
listening: {{.Vars.NODE_ACTIVE}}
ip: ["[% sip_proxy_ip %]"]
[% ELSIF is_lb -%]
# HAProxy: Prosody (xmpp-client)
tcp:5222:
listening: [% haproxy.enable == 'yes' ? 'true' : 'false' %]
ip: ["[% sip_ext_ips.0 %]"]
[% END -%]
[% IF is_proxy -%]
# Prosody (xmpp-server)
tcp:5269:
listening: {{.Vars.NODE_ACTIVE}}
ip: ["[% sip_proxy_ip %]"]
[% ELSIF is_lb -%]
# HAProxy: Prosody (xmpp-server)
tcp:5269:
listening: [% haproxy.enable == 'yes' ? 'true' : 'false' %]
ip: ["[% sip_ext_ips.0 %]"]
[% END -%]
[% IF is_proxy -%]
# Prosody (http)
tcp:5280:
listening: {{.Vars.NODE_ACTIVE}}
ip: ["[% sip_int_ips.0 %]"]
[% END -%]
[% IF is_proxy -%]
# Prosody (https)
tcp:5281:
listening: {{.Vars.NODE_ACTIVE}}
ip: ["[% sip_int_ips.0 %]"]
[% ELSIF is_lb -%]
# HAProxy: Prosody (http)
tcp:5281:
listening: [% haproxy.enable == 'yes' ? 'true' : 'false' %]
ip: ["[% sip_ext_ips.0 %]"]
[% END -%]
[% IF is_proxy -%]
# Prosody (ctrl)
tcp:5582:
listening: {{.Vars.NODE_ACTIVE}}
ip: ["[% sip_int_ips.0 %]"]
[% END -%]
[% IF is_lb -%]
# HAProxy admin
tcp:8080:
listening: [% haproxy.enable == 'yes' && haproxy.admin == 'yes' ? 'true' : 'false' %]
ip: ["[% sip_ext_ips.0 %]"]
[% END -%]
[% IF is_proxy -%]
[% IF b2b.enable == "yes" -%]
# SEMS: XMLRPC server of B2B
tcp:[% b2b.xmlrpcport %]:

Loading…
Cancel
Save