This repository hosts the cloud.vmware_ops
validated Ansible Collection.
The collection includes a variety of Ansible roles and playbooks to help automate the management of VMware.
It focuses on playbooks and roles that allow users to quickly and easily perform VMware operations tasks. The playbooks cover common use cases and leverage the roles inside the collection. The roles can be used to create your own playbooks and cover custom use cases for your environment.
This repository comes with an execution environment definition. This can be used to quickly build a container image that contains all of the software required to run the playbooks and roles in this repository. See execution-environment/README.md for more information.
It is common for people to use localhost
to run the tasks in this content since most tasks simply interact with the vSphere environment. If you do not use the execution environment mentioned above, the following requirements are needed on whatever host runs the tasks:
Once the collection is installed, you can install the python requirements using pip: pip install -r ~/.ansible/collections/ansible_collections/cloud/vmware_ops/execution-environment/requirements.txt
This collection supports vSphere 7.x and 8.x.
This collection has been tested against following Ansible versions: >=2.15.0.
Required collections are listed in the galaxy.yml
and will be installed automatically when this collection is installed.
This content can be installed from git by anyone with access to the repository.
To consume this Validated Content from Automation Hub, please ensure that you add the following lines to your ansible.cfg file.
# if you have multiple server configurations (validated content, certified content, public content, etc) you can specify those config
# section names here as a comma separated list. For example 'server_list = validated,public,my_galaxy
[galaxy]
server_list = validated
[galaxy_server.validated]
url=https://console.redhat.com/api/automation-hub/content/validated/
auth_url=https://sso.redhat.com/auth/realms/redhat-external/protocol/openid-connect/token
token=<SuperSecretToken>
The token can be obtained from the Automation Hub Web UI.
Once the above steps are done, you can run the following command to install the collection.
ansible-galaxy collection install cloud.vmware_ops
Once installed, you can reference the cloud.vmware_ops collection content by its fully qualified collection name (FQCN), for example:
- hosts: localhost
roles:
- role: cloud.vmware_ops.system_settings
Use Case Name: Create and Modify Cluster Settings and Perform ESXi Maintenance
cloud.vmware_ops.cluster_settings
- Set DPM, DRS, vCLS, HA, and vSAN settingscloud.vmware_ops.esxi_maintenance_mode
- Manage the maintenance status of an ESXi hostmanage_all_settings
playbook, control a variety of settings in vCenteresxi_maintenance_mode
rolecluster_settings
role to adjust related settings.Use Case Name: Create and Manage Virtual ESXi Hosts and a Nested VCenter
cloud.vmware_ops.provision_virtual_esxi
- Provision a set of virtual ESXi hosts on an existing vSphere environmentcloud.vmware_ops.vcenter_host_connection
- Manage the connection status of an ESXi host to a vCenter appliancecloud.vmware_ops.system_settings
- Manage the system settings of a vCenter appliancecloud.vmware_ops.provision_vcenter
- Provision a vCenter appliance on an ESXi host or on an existing vCenter clusterprovision_virtual_esxi
roleprovision_vcenter
role or provision_vcsa_on_esxi
playbookadd_esxi_host_from_vcenter
playbook or vcenter_host_connection
rolesystem_settings
playbook or system_settings
roleUse Case Name: Manage a VM and Export and/or Deploy as an OVF
cloud.vmware_ops.export_vm_as_ovf
- Exports an existing VM as an OVF filecloud.vmware_ops.provision_vm
- Create, manage, or delete a VMcloud.vmware_ops.snapshot_management
- Manage the snapshots of a VMcloud.vmware_ops.manage_folder
- Create or delete a foldercloud.vmware_ops.deploy_ovf
- Deploy an OVF file to an ESXi host or existing vCenter Clusterprovision_vm
role or manage_vm
playbooksnapshot_management
role or create_snapshot
playbookprovision_vm
role or manage_vm
playbookexport_vm_as_ovf
playbook or export_vm_as_ovf
roledeploy_ovf
playbook or deploy_ovf
roleAll releases will meet the following test criteria.
This community is currently not accepting direct contributions. We encourage you to open git issues for bugs, comments or feature requests.
Refer to the Ansible community guide.
Join the Ansible forum:
The Ansible Bullhorn newsletter: used to announce releases and important changes.
For more information about communication, see the Ansible communication guide.
As Red Hat Ansible Validated Content, this collection is entitled to limited support through Ansible Automation Platform (AAP).
GNU General Public License v3.0 or later
See LICENSE to see the full text.