A new parameter called "type" is now allowed in the backend to
choose the image type of the VM template. The default image type, if
this parameter isn't used, is "qcow2".
Examples:
- creates a VM template called "opensuse_disktype" with 2 disks, one of them is
of type "raw":
$ curl -u user:passwd -H "Content-Type: application/json" -H "Accept:
application/json"
http://localhost:8010/templates -X POST -d'{"name":
"opensuse_disktype",
"cdrom":"/home/danielhb/Downloads/openSUSE-13.1-DVD-x86_64.iso",
"disks":[{"index":0,"size":3}, {"index":1,
"size":4, "type":"raw"}]}'
- changing the disk types of the template:
$ curl -u user:passwd -H "Content-Type: application/json" -H "Accept:
application/json"
http://localhost:8010/templates/opensuse_disktype -X PUT
-d'{"disks":[{"index":0,"size":3,
"type":"raw"}, {"index":1, "size":4}]}'
Daniel Henrique Barboza (1):
Choose disk image type in vm template - backend
docs/API.md | 1 +
src/kimchi/API.json | 12 ++++++++++++
src/kimchi/i18n.py | 1 +
src/kimchi/vmtemplate.py | 5 ++++-
4 files changed, 18 insertions(+), 1 deletion(-)
--
1.8.3.1