1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-21 14:50:08 +03:00

B #2828: vCenter template without any nic do not fail at deploy

This commit is contained in:
sergio semedi 2019-01-18 15:37:21 +01:00 committed by Tino Vázquez
parent fad4a1c454
commit 24af2b77d2

View File

@ -1573,7 +1573,7 @@ class VirtualMachine < VCenterDriver::Template
end
# grab the last unitNumber to ensure the nic to be added at the end
@unic = @unic || get_vcenter_nics.map{|d| d.unitNumber}.max rescue 0
@unic = @unic || get_vcenter_nics.map{|d| d.unitNumber}.max || 0
card_spec = {
:key => 0,
:deviceInfo => {