From 536c22b12f1c819a1f02982d84f2fa2258a9e4c3 Mon Sep 17 00:00:00 2001 From: Sergio Semedi Barranco Date: Mon, 10 Sep 2018 11:57:48 +0200 Subject: [PATCH] B #2324: vcenter create_net hook checks IMPORTED (#2404) --- share/hooks/vcenter/create_vcenter_net.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/share/hooks/vcenter/create_vcenter_net.rb b/share/hooks/vcenter/create_vcenter_net.rb index 6108a9cc40..80ebd3ec34 100755 --- a/share/hooks/vcenter/create_vcenter_net.rb +++ b/share/hooks/vcenter/create_vcenter_net.rb @@ -72,10 +72,11 @@ end one_vnet.lock(1) esx_rollback = [] #Track hosts that require a rollback managed = one_vnet["TEMPLATE/OPENNEBULA_MANAGED"] != "NO" +imported = one_vnet["TEMPLATE/VCENTER_IMPORTED"] begin # Step 0. Only execute for vcenter network driver && managed by one - if one_vnet["VN_MAD"] == "vcenter" && managed + if one_vnet["VN_MAD"] == "vcenter" && managed && imported.nil? wait_vlanid(one_vnet) if one_vnet["VLAN_ID_AUTOMATIC"] == '1' # Step 1. Extract vnet settings host_id = one_vnet["TEMPLATE/VCENTER_ONE_HOST_ID"]