mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-21 14:50:08 +03:00
F #~: fix root template (#1047)
Signed-off-by: Carlos Herrera <cherrera@opennebula.io>
This commit is contained in:
parent
54d40162ce
commit
0de1ef3780
@ -1659,10 +1659,12 @@ module VCenterDriver
|
||||
folders = []
|
||||
until item.instance_of? RbVmomi::VIM::Datacenter
|
||||
item = item.parent
|
||||
first_condition = item.instance_of? RbVmomi::VIM::Datacenter
|
||||
second_condition = item.name != 'vm'
|
||||
first_condition =
|
||||
!(item.instance_of? RbVmomi::VIM::Datacenter)
|
||||
second_condition =
|
||||
item.name != 'vm'
|
||||
|
||||
unless first_condition && second_condition
|
||||
if first_condition && second_condition
|
||||
folders << item.name
|
||||
end
|
||||
if item.nil?
|
||||
@ -1693,8 +1695,8 @@ module VCenterDriver
|
||||
one_tmp[:dc_name] = dc_name
|
||||
one_tmp[:template_name] = template_name
|
||||
one_tmp[:sunstone_template_name]=
|
||||
"#{template_name} [ Cluster: #{template_ccr_name} \
|
||||
- Template location: #{location} ]"
|
||||
"#{template_name} [ Cluster: #{template_ccr_name}" \
|
||||
"- Template location: #{location} ]"
|
||||
one_tmp[:template_location] = location
|
||||
one_tmp[:vcenter_ccr_ref] = template_ccr_ref
|
||||
one_tmp[:vcenter_ref] = template_ref
|
||||
|
Loading…
x
Reference in New Issue
Block a user