community.vmware.vmware_content_deploy_ovf_template – Deploy Virtual Machine from ovf template stored in content library.¶
Note
This plugin is part of the community.vmware collection (version 1.9.0).
To install it use: ansible-galaxy collection install community.vmware
.
To use it in a playbook, specify: community.vmware.vmware_content_deploy_ovf_template
.
Synopsis¶
Module to deploy virtual machine from ovf template in content library.
All variables and VMware object names are case sensitive.
Requirements¶
The below requirements are needed on the host that executes this module.
python >= 2.6
PyVmomi
vSphere Automation SDK
Parameters¶
Examples¶
- name: Deploy Virtual Machine from OVF template in content library
community.vmware.vmware_content_deploy_ovf_template:
hostname: '{{ vcenter_hostname }}'
username: '{{ vcenter_username }}'
password: '{{ vcenter_password }}'
ovf_template: rhel_test_template
datastore: Shared_NFS_Volume
folder: vm
datacenter: Sample_DC_1
name: Sample_VM
resource_pool: test_rp
delegate_to: localhost
- name: Deploy Virtual Machine from OVF template in content library with eagerZeroedThick storage
vmware_content_deploy_ovf_template:
hostname: '{{ vcenter_hostname }}'
username: '{{ vcenter_username }}'
password: '{{ vcenter_password }}'
ovf_template: rhel_test_template
datastore: Shared_NFS_Volume
folder: vm
datacenter: Sample_DC_1
name: Sample_VM
resource_pool: test_rp
storage_provisioning: eagerZeroedThick
delegate_to: localhost
Return Values¶
Common return values are documented here, the following are the fields unique to this module:
Key | Returned | Description |
---|---|---|
vm_deploy_info
dictionary
|
on success |
Virtual machine deployment message and vm_id
Sample:
{'msg': "Deployed Virtual Machine 'Sample_VM'.", 'vm_id': 'vm-1009'}
|
Authors¶
Lev Goncharv (@ultral)