Fix Bug 2159: Use provider-network profile when specified even if it's overlay or... 94/12794/1 v12.0.5
authorGabriel Cuba <gcuba@whitestack.com>
Wed, 14 Dec 2022 23:33:50 +0000 (18:33 -0500)
committercubag <gcuba@whitestack.com>
Mon, 19 Dec 2022 21:32:40 +0000 (22:32 +0100)
Change-Id: Ib1f910e0f8ce9ed5fbb6ffbcb09847c90c2c9710
Signed-off-by: Gabriel Cuba <gcuba@whitestack.com>
(cherry picked from commit 0d8ce07a6fd75ce185e0b35826b0baedb60bfa43)

NG-RO/osm_ng_ro/ns.py
RO-VIM-openstack/osm_rovim_openstack/vimconn_openstack.py
releasenotes/notes/fix_bug_2159-0f354a90f97425bb.yaml [new file with mode: 0644]

index b71f1b4..1308fbd 100644 (file)
@@ -920,7 +920,7 @@ class Ns(object):
                     "id": vim_info.get("vim_network_id"),
                 },
             }
-        elif target_vld.get("mgmt-network"):
+        elif target_vld.get("mgmt-network") and not vim_info.get("provider_network"):
             extra_dict["find_params"] = {
                 "mgmt": True,
                 "name": target_vld["id"],
index eda5699..934cde9 100644 (file)
@@ -753,7 +753,7 @@ class vimconnector(vimconn.VimConnector):
             self._reload_connection()
             network_dict = {"name": net_name, "admin_state_up": True}
 
-            if net_type in ("data", "ptp"):
+            if net_type in ("data", "ptp") or provider_network_profile:
                 provider_physical_network = None
 
                 if provider_network_profile and provider_network_profile.get(
diff --git a/releasenotes/notes/fix_bug_2159-0f354a90f97425bb.yaml b/releasenotes/notes/fix_bug_2159-0f354a90f97425bb.yaml
new file mode 100644 (file)
index 0000000..22d4053
--- /dev/null
@@ -0,0 +1,21 @@
+#######################################################################################
+# Copyright ETSI Contributors and Others.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+# implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#######################################################################################
+---
+fixes:
+  - |
+    This fixes the bug 2159. RO will create the network with the provided provider-network 
+    profile when specified, even if it's an overlay network or a management network.