Commit 06326eea by Bálint Máhonfai

Add qcow2 format to export options

parent 6ac9d76c
......@@ -38,7 +38,6 @@ class Disk(object):
TYPES = ['snapshot', 'normal']
FORMATS = ['qcow2', 'raw', 'iso']
CREATE_FORMATS = ['qcow2', 'raw']
EXPORT_FORMATS = ['vdi', 'vpc', 'vmdk']
def __init__(self, dir, name, format, type, size,
base_name, actual_size=0):
......@@ -267,13 +266,11 @@ class Disk(object):
"iso files are allowed. Image from: %s" % url)
def export(self, format):
if format not in self.EXPORT_FORMATS:
raise Exception('Invalid export format: %s' % format)
format_dict = {
'vmdk': 'vmdk',
'qcow2': 'qcow2',
'vdi': 'vdi',
'vpc': 'vhd',
'vmdk': 'vmdk',
cmdline = ['qemu-img',
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