Commit abf7af60 by Guba Sándor

instance: set iso base when it's cloning

parent 700fbcf7
......@@ -171,9 +171,12 @@ class InstanceTemplate(AclBase, VirtualMachineDescModel, TimeStampedModel):
tmpl.save()
def __clone_disk(disk):
base = None
if disk.type == "iso":
base = disk
cloned_disk = Disk.create(datastore=disk.datastore,
name=disk.name, size=disk.size,
type=disk.type)
type=disk.type, base=base)
#Paralell cloning disks
disk.clone_async(cloned_disk, user=user)
return cloned_disk
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment