Parameter |
Choices/Defaults |
Comments |
account
|
|
Account the template, snapshot or VM is related to.
|
api_http_method
|
|
HTTP method used to query the API endpoint.
If not given, the CLOUDSTACK_METHOD env variable is considered.
As the last option, the value is taken from the ini config file, also see the notes.
Fallback value is get if not specified.
|
api_key
|
|
API key of the CloudStack API.
If not given, the CLOUDSTACK_KEY env variable is considered.
As the last option, the value is taken from the ini config file, also see the notes.
|
api_region
|
Default:
cloudstack
|
Name of the ini section in the cloustack.ini file.
If not given, the CLOUDSTACK_REGION env variable is considered.
|
api_secret
|
|
Secret key of the CloudStack API.
If not set, the CLOUDSTACK_SECRET env variable is considered.
As the last option, the value is taken from the ini config file, also see the notes.
|
api_timeout
|
|
HTTP timeout in seconds.
If not given, the CLOUDSTACK_TIMEOUT env variable is considered.
As the last option, the value is taken from the ini config file, also see the notes.
Fallback value is 10 seconds if not specified.
|
api_url
|
|
URL of the CloudStack API e.g. https://cloud.example.com/client/api.
If not given, the CLOUDSTACK_ENDPOINT env variable is considered.
As the last option, the value is taken from the ini config file, also see the notes.
|
bits
|
|
32 or 64 bits support.
|
checksum
|
|
The MD5 checksum value of this template.
If set, we search by checksum instead of name.
|
cross_zones
bool |
|
Whether the template should be synced or removed across zones.
Only used if state is present or absent.
|
details
|
|
Template details in key/value pairs.
|
display_text
|
|
Display text of the template.
|
domain
|
|
Domain the template, snapshot or VM is related to.
|
format
|
Choices:
- QCOW2
- RAW
- VHD
- OVA
|
The format for the template.
Only considered if state=present.
|
hypervisor
|
Choices:
- KVM
- kvm
- VMware
- vmware
- BareMetal
- baremetal
- XenServer
- xenserver
- LXC
- lxc
- HyperV
- hyperv
- UCS
- ucs
- OVM
- ovm
- Simulator
- simulator
|
Name the hypervisor to be used for creating the new template.
Relevant when using state=present.
|
is_dynamically_scalable
bool |
|
Register the template having XS/VMWare tools installed in order to support dynamic scaling of VM CPU/memory.
Only used if state is present.
|
is_extractable
bool |
|
Allows the template or its derivatives to be extractable.
|
is_featured
bool |
|
Register the template to be featured.
Only used if state is present.
|
is_public
bool |
|
Register the template to be publicly available to all users.
Only used if state is present.
|
is_ready
bool |
|
Note: this flag was not implemented and therefore marked as deprecated.
Deprecated, will be removed in version 2.11.
|
is_routing
bool |
|
Sets the template type to routing, i.e. if template is used to deploy routers.
Only considered if url is used.
|
mode
|
Choices:
http_download ←
- ftp_upload
|
Mode for the template extraction.
Only used if state=extracted.
|
name
required |
|
Name of the template.
|
os_type
|
|
OS type that best represents the OS of this template.
|
password_enabled
bool |
|
Enable template password reset support.
|
poll_async
bool |
|
Poll async jobs until job has finished.
|
project
|
|
Name of the project the template to be registered in.
|
requires_hvm
bool |
|
Whether the template requires HVM or not.
Only considered while creating the template.
|
snapshot
|
|
Name of the snapshot, created from the VM ROOT volume, the template will be created from.
vm is required together with this argument.
|
sshkey_enabled
bool |
|
True if the template supports the sshkey upload feature.
Only considered if url is used (API limitation).
|
state
|
Choices:
present ←
- absent
- extracted
|
State of the template.
|
tags
(added in 2.4) |
|
List of tags. Tags are a list of dictionaries having keys key and value .
To delete all tags, set a empty list e.g. tags: [] .
aliases: tag
|
template_filter
|
Choices:
- all
- featured
self ←
- selfexecutable
- sharedexecutable
- executable
- community
|
Name of the filter used to search for the template.
The filter all was added in 2.7.
|
template_find_options
(added in 2.7) |
Choices:
- display_text
- checksum
- cross_zones
Default:
[]
|
Options to find a template uniquely.
More than one allowed.
aliases: template_find_option
|
template_tag
|
|
The tag for this template.
|
url
|
|
URL of where the template is hosted on state=present.
URL to which the template would be extracted on state=extracted.
Mutually exclusive with vm .
|
vm
|
|
VM name the template will be created from its volume or alternatively from a snapshot.
VM must be in stopped state if created from its volume.
Mutually exclusive with url .
|
zone
|
|
Name of the zone you wish the template to be registered or deleted from.
If not specified, first found zone will be used.
|