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

M #-: escape special chars in vCenter disk names (#387)

(cherry picked from commit 06a37707fe8aebcc704d6d76643d9b4f39861ef3)
This commit is contained in:
Alejandro Huertas Herrero 2020-11-03 16:19:00 +01:00 committed by Tino Vazquez
parent 36abb7d97f
commit e7781c687a
No known key found for this signature in database
GPG Key ID: 14201E424D02047E

View File

@ -465,10 +465,8 @@ module VirtualMachineMonitor
info_disks.each do |disk|
next if disk[1].no_exists?
name = disk[0]
# Delete special characters
name.gsub!(/[^0-9A-Za-z]/, '_')
name = disk[0].gsub(/[^0-9A-Za-z]/, '_')
str_info << "DISK_#{name}_ACTUAL_PATH=\"[" <<
disk[1].ds.name << '] ' << disk[1].path << '" ' << "\n"