mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-21 14:50:08 +03:00
Enable rm_directory for vcenter 6.5
This commit is contained in:
parent
00b7d8607a
commit
e04dba14e4
@ -79,8 +79,7 @@ begin
|
||||
ds.delete_file(img_src)
|
||||
end
|
||||
|
||||
vcenter_version = vi_client.vim.serviceContent.about.apiVersion
|
||||
ds.rm_directory(img_dir) if ds.dir_empty?(img_dir) && vcenter_version != "6.5"
|
||||
ds.rm_directory(img_dir) if ds.dir_empty?(img_dir)
|
||||
|
||||
rescue Exception => e
|
||||
if !e.message.start_with?('FileNotFound')
|
||||
|
@ -119,8 +119,7 @@ if path.match(/disk\.\d+$/)
|
||||
|
||||
ds.delete_virtual_disk(img_path)
|
||||
img_dir = File.dirname(img_path)
|
||||
vcenter_version = vi_client.vim.serviceContent.about.apiVersion
|
||||
ds.rm_directory(img_dir) if ds.dir_empty?(img_dir) && vcenter_version != "6.5"
|
||||
ds.rm_directory(img_dir) if ds.dir_empty?(img_dir)
|
||||
|
||||
rescue Exception => e
|
||||
if !e.message.start_with?('FileNotFound')
|
||||
|
Loading…
x
Reference in New Issue
Block a user