From 2bd0012a6e1fc0decad9522ab1d50491f991cbe1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Harald=20Jens=C3=A5s?= Date: Wed, 12 Jun 2019 10:44:36 +0200 Subject: [PATCH] Fix RedisVirtualIP when overrdiing InternalApi name_lower When overriding RedisVirtualIP name_lower and using the service_net_map_replace the overridden name_lower is was not used in VipSubnetMapDefaults. Get name_lower from the _service_nets jinja2 variable which holds the replaced name_lower for the network when service_net_map_replace is used. Closes-Bug: #1832461 Change-Id: I839474dcce749fc3a75ae0e1be16780ddb83f5b3 --- network/service_net_map.j2.yaml | 2 +- ...-InternalApi-name-lower-override-7ea2635877b753c7.yaml | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) create mode 100644 releasenotes/notes/bug-1832461-RedisVirtualIP-and-InternalApi-name-lower-override-7ea2635877b753c7.yaml diff --git a/network/service_net_map.j2.yaml b/network/service_net_map.j2.yaml index 27319f5735..6b2d6d31a4 100644 --- a/network/service_net_map.j2.yaml +++ b/network/service_net_map.j2.yaml @@ -124,7 +124,7 @@ parameters: {%- for network in networks if network.vip|default(false) %} {{network.name}}: {{network.name_lower}}_subnet {%- endfor %} - redis: internal_api_subnet + redis: {{ _service_nets.get('internal_api', 'internal_api') }}_subnet type: json # We define mappings to work around names that break when doing the diff --git a/releasenotes/notes/bug-1832461-RedisVirtualIP-and-InternalApi-name-lower-override-7ea2635877b753c7.yaml b/releasenotes/notes/bug-1832461-RedisVirtualIP-and-InternalApi-name-lower-override-7ea2635877b753c7.yaml new file mode 100644 index 0000000000..1a907f36b7 --- /dev/null +++ b/releasenotes/notes/bug-1832461-RedisVirtualIP-and-InternalApi-name-lower-override-7ea2635877b753c7.yaml @@ -0,0 +1,8 @@ +--- +fixes: + - | + When changeing the ``name_lower`` of the ``InternalApi`` network and using + the ``service_net_map_replace`` option in network data. The subnet + referenced in ``VipSubnetMapDefaults`` did not take in account the custom + lowercase name for the network, causing deployment error. + See bug: `1832461 `_.