|
|
@ -2214,7 +2214,7 @@ class PyVmomiHelper(PyVmomi):
|
|
|
|
# Convert disk present in template if is set
|
|
|
|
# Convert disk present in template if is set
|
|
|
|
if self.params['convert']:
|
|
|
|
if self.params['convert']:
|
|
|
|
for device in vm_obj.config.hardware.device:
|
|
|
|
for device in vm_obj.config.hardware.device:
|
|
|
|
if hasattr(device.backing, 'fileName'):
|
|
|
|
if isinstance(device, vim.vm.device.VirtualDisk):
|
|
|
|
disk_locator = vim.vm.RelocateSpec.DiskLocator()
|
|
|
|
disk_locator = vim.vm.RelocateSpec.DiskLocator()
|
|
|
|
disk_locator.diskBackingInfo = vim.vm.device.VirtualDisk.FlatVer2BackingInfo()
|
|
|
|
disk_locator.diskBackingInfo = vim.vm.device.VirtualDisk.FlatVer2BackingInfo()
|
|
|
|
if self.params['convert'] in ['thin']:
|
|
|
|
if self.params['convert'] in ['thin']:
|
|
|
|