mirror of
https://github.com/OpenNebula/one.git
synced 2024-12-23 17:33:56 +03:00
parent
a664466ee9
commit
d0498534d8
@ -89,14 +89,15 @@ if OpenNebula.is_error?(rc)
|
||||
exit(1)
|
||||
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']
|
||||
|
||||
return unless one_vnet['VN_MAD'] == 'vcenter' && managed && imported.nil?
|
||||
|
||||
begin
|
||||
# Step 0. Only execute for vcenter network driver && managed by one
|
||||
if one_vnet['VN_MAD'] == 'vcenter' && managed && imported.nil?
|
||||
one_vnet.lock(1)
|
||||
wait_vlanid(one_vnet) if one_vnet['VLAN_ID_AUTOMATIC'] == '1'
|
||||
|
||||
# Step 1. Extract vnet settings
|
||||
@ -139,12 +140,6 @@ begin
|
||||
ls_vni = nil
|
||||
net_info = ''
|
||||
|
||||
# NSX
|
||||
# nsxmgr = one_host['TEMPLATE/NSX_MANAGER']
|
||||
# nsx_user = one_host['TEMPLATE/NSX_USER']
|
||||
# nsx_pass_enc = one_host['TEMPLATE/NSX_MANAGER']
|
||||
# NSX
|
||||
|
||||
if pg_type == VCenterDriver::Network::NETWORK_TYPE_NSXV
|
||||
nsx_client = NSXDriver::NSXClient.new(host_id)
|
||||
virtual_wire_spec =
|
||||
@ -337,7 +332,7 @@ begin
|
||||
|
||||
one_vnet.lock(1)
|
||||
end
|
||||
end
|
||||
|
||||
rescue StandardError => e
|
||||
STDERR.puts("#{e.message}/#{e.backtrace}")
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user