ansible / ansible.builtin / v2.9.27 / module / ovirt oVirt/RHEV platform management | "added in version" 1.4 of ansible.builtin" Authors: Vincent Van der Kussen (@vincentvdk) preview | supported by communityansible.builtin.ovirt (v2.9.27) — module
pip
Install with pip install ansible==2.9.27
This module only supports oVirt/RHEV version 3. A newer module M(ovirt_vm) supports oVirt/RHV version 4.
Allows you to create new instances, either from scratch or an image, in addition to deleting or stopping instances on the oVirt/RHEV platform.
- name: Basic example to provision from image ovirt: user: admin@internal url: https://ovirt.example.com instance_name: ansiblevm04 password: secret image: centos_64 zone: cluster01 resource_type: template
- name: Full example to create new instance from scratch ovirt: instance_name: testansible resource_type: new instance_type: server user: admin@internal password: secret url: https://ovirt.example.com instance_disksize: 10 zone: cluster01 region: datacenter1 instance_cpus: 1 instance_nic: nic1 instance_network: rhevm instance_mem: 1000 disk_alloc: thin sdomain: FIBER01 instance_cores: 1 instance_os: rhel_6x64 disk_int: virtio
- name: Stopping an existing instance ovirt: instance_name: testansible state: stopped user: admin@internal password: secret url: https://ovirt.example.com
- name: Start an existing instance ovirt: instance_name: testansible state: started user: admin@internal password: secret url: https://ovirt.example.com
- name: Start an instance with cloud init information ovirt: instance_name: testansible state: started user: admin@internal password: secret url: https://ovirt.example.com hostname: testansible domain: ansible.local ip: 192.0.2.100 netmask: 255.255.255.0 gateway: 192.0.2.1 rootpw: bigsecret
url: description: - The url of the oVirt instance. required: true user: description: - The user to authenticate with. required: true zone: description: - Deploy the image to this oVirt cluster. image: description: - The template to use for the instance. state: choices: - absent - present - restarted - shutdown - started default: present description: - Create, terminate or remove instances. region: description: - The oVirt/RHEV datacenter where you want to deploy to. sdomain: description: - The Storage Domain where you want to create the instance's disk on. disk_int: choices: - ide - virtio default: virtio description: - Interface type of the disk. password: description: - Password of the user to authenticate with. required: true disk_alloc: choices: - preallocated - thin default: thin description: - Define whether disk is thin or preallocated. instance_ip: aliases: - ip description: - Define the instance's IP. version_added: '2.1' version_added_collection: ansible.builtin instance_os: aliases: - vmos description: - Type of Operating System. instance_dns: aliases: - dns description: - Define the instance's Primary DNS server. version_added: '2.1' version_added_collection: ansible.builtin instance_key: aliases: - key description: - Define the instance's Authorized key. version_added: '2.1' version_added_collection: ansible.builtin instance_mem: aliases: - vmmem description: - The instance's amount of memory in MB. instance_nic: aliases: - vmnic description: - The name of the network interface in oVirt/RHEV. instance_cpus: aliases: - vmcpus default: 1 description: - The instance's number of CPUs. instance_name: aliases: - vmname description: - The name of the instance to use. required: true instance_type: aliases: - vmtype choices: - desktop - server - high_performance default: server description: - Define whether the instance is a server, desktop or high_performance. - I(high_performance) is supported since Ansible 2.5 and oVirt/RHV 4.2. resource_type: choices: - new - template description: - Whether you want to deploy an image or create an instance from scratch. instance_cores: aliases: - vmcores default: 1 description: - Define the instance's number of cores. instance_domain: aliases: - domain description: - Define the instance's Domain. version_added: '2.1' version_added_collection: ansible.builtin instance_rootpw: aliases: - rootpw description: - Define the instance's Root password. version_added: '2.1' version_added_collection: ansible.builtin instance_netmask: aliases: - netmask description: - Define the instance's Netmask. version_added: '2.1' version_added_collection: ansible.builtin instance_network: aliases: - vmnetwork default: rhevm description: - The logical network the machine should belong to. instance_disksize: aliases: - vm_disksize description: - Size of the instance's disk in GB. instance_hostname: aliases: - hostname description: - Define the instance's Hostname. version_added: '2.1' version_added_collection: ansible.builtin