ServerMania logo

Edit Template

To edit a template, use the following request:

PUT /templates/:id.xml
PUT /templates/:id.json

XML Request Example

curl -i -X PUT -H 'Accept: application/xml' -H 'Content-type:application/xml' -u user:userpass -d '<image_template><label>zaza_loc12</label><file_name>vmwsyfugaqwq6r_20130613175624</file_name><version>1.3</version><min_disk_size>10</min_disk_size><min_memory_size>512</min_memory_size></image_template>' --url http://test/templates/2.xml

JSON Request Example

curl -i -X PUT -H 'Accept: application/json' -H 'Content-type:application/json' -u user:userpass -d '{"image_template":{"label":"zaza_loc12","file_name":"vmwsyfugaqwq6r_20130613175624","version":"1.3","min_disk_size": "10","min_memory_size": "512"}}' --url http://test/templates/2.json

Where you can edit:

label – the template title

file_name – the name of the template file

version – file version

min_disk_size – minimum disk size required to build a VS on this template (GB)

min_memory_size - minimum memory size required to build a VS on this template (MB)

allowed_hot_migrate - true if hot migration for VS, created from this template, is enabled; otherwise false


Page History

v.5.5

  • added the allowed_hot_migrate parameter