mirror of
https://github.com/OpenNebula/one.git
synced 2025-02-27 13:57:23 +03:00
vCenter Resource pools fixed, securing ds browsing (#2142)
This commit is contained in:
parent
d8e579d5a3
commit
a00f82f778
@ -572,7 +572,9 @@ class Datastore < Storage
|
||||
|
||||
# Remove [datastore] from file path
|
||||
folderpath = ""
|
||||
size = result.folderPath.size
|
||||
if result.folderPath[-1] != "]"
|
||||
result.folderPath[size] = '/' if result.folderPath[-1] != '/'
|
||||
folderpath = result.folderPath.sub(/^\[#{ds_name}\] /, "")
|
||||
end
|
||||
|
||||
|
@ -1253,7 +1253,8 @@ class VirtualMachine < Template
|
||||
|
||||
#Get ref for req_rp
|
||||
rp_list = cluster.get_resource_pool_list
|
||||
req_rp_ref = rp_list.select { |rp| rp[:name].downcase == req_rp }.first[:ref] rescue nil
|
||||
req_rp_ref = rp_list.select { |rp| rp[:name].downcase == req_rp.downcase }.first[:ref] rescue nil
|
||||
|
||||
|
||||
if vi_client.rp_confined?
|
||||
if req_rp_ref && req_rp_ref != vi_client.rp._ref
|
||||
|
Loading…
x
Reference in New Issue
Block a user