community.vmware.vmware_guest_tools_wait – Wait for VMware tools to become available¶
Note
This plugin is part of the community.vmware collection (version 1.7.0).
To install it use: ansible-galaxy collection install community.vmware
.
To use it in a playbook, specify: community.vmware.vmware_guest_tools_wait
.
Synopsis¶
This module can be used to wait for VMware tools to become available on the given VM and return facts.
Requirements¶
The below requirements are needed on the host that executes this module.
python >= 2.6
PyVmomi
Parameters¶
Examples¶
- name: Wait for VMware tools to become available by UUID
vmware_guest_facts:
hostname: "{{ vcenter_hostname }}"
username: "{{ vcenter_username }}"
password: "{{ vcenter_password }}"
datacenter: "{{ datacenter }}"
folder: "/{{datacenter}}/vm"
name: "{{ vm_name }}"
delegate_to: localhost
register: vm_facts
- name: Get UUID from previous task and pass it to this task
community.vmware.vmware_guest_tools_wait:
hostname: "{{ vcenter_hostname }}"
username: "{{ vcenter_username }}"
password: "{{ vcenter_password }}"
uuid: "{{ vm_facts.instance.hw_product_uuid }}"
delegate_to: localhost
register: facts
- name: Wait for VMware tools to become available by MoID
community.vmware.vmware_guest_tools_wait:
hostname: "{{ vcenter_hostname }}"
username: "{{ vcenter_username }}"
password: "{{ vcenter_password }}"
moid: vm-42
delegate_to: localhost
register: facts
- name: Wait for VMware tools to become available by name
community.vmware.vmware_guest_tools_wait:
hostname: "{{ vcenter_hostname }}"
username: "{{ vcenter_username }}"
password: "{{ vcenter_password }}"
name: test-vm
folder: "/{{datacenter}}/vm"
delegate_to: localhost
register: facts
Return Values¶
Common return values are documented here, the following are the fields unique to this module:
Key | Returned | Description |
---|---|---|
instance
dictionary
|
always |
metadata about the virtual machine
Sample:
None
|
Authors¶
Philippe Dellaert (@pdellaert) <philippe@dellaert.org>