From 7cfcf18a8cfbe74309c3bc64c825e5208d99ff55 Mon Sep 17 00:00:00 2001 From: chashtag <12386331+chashtag@users.noreply.github.com> Date: Fri, 20 Sep 2019 09:40:14 -0400 Subject: [PATCH] Update ovirt_vm.py (#62425) * Update ovirt_vm.py --- lib/ansible/modules/cloud/ovirt/ovirt_vm.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/lib/ansible/modules/cloud/ovirt/ovirt_vm.py b/lib/ansible/modules/cloud/ovirt/ovirt_vm.py index 9980ec4d102..91e47557e5a 100644 --- a/lib/ansible/modules/cloud/ovirt/ovirt_vm.py +++ b/lib/ansible/modules/cloud/ovirt/ovirt_vm.py @@ -835,6 +835,10 @@ options: - "VM should have snapshot specified by C(snapshot)." - "If C(snapshot_name) specified C(snapshot_vm) is required." version_added: "2.9" + custom_emulated_machine: + description: + - "Sets the value of the custom_emulated_machine attribute." + version_added: "2.10" notes: - If VM is in I(UNASSIGNED) or I(UNKNOWN) state before any operation, the module will fail. @@ -1374,6 +1378,7 @@ class VmsModule(BaseModule): use_latest_template_version=self.param('use_latest_template_version'), stateless=self.param('stateless') or self.param('use_latest_template_version'), delete_protected=self.param('delete_protected'), + custom_emulated_machine=self.param('custom_emulated_machine'), bios=( otypes.Bios(boot_menu=otypes.BootMenu(enabled=self.param('boot_menu'))) ) if self.param('boot_menu') is not None else None, @@ -1585,6 +1590,7 @@ class VmsModule(BaseModule): equal(self.param('stateless'), entity.stateless) and equal(self.param('cpu_shares'), entity.cpu_shares) and equal(self.param('delete_protected'), entity.delete_protected) and + equal(self.param('custom_emulated_machine'), entity.custom_emulated_machine) and equal(self.param('use_latest_template_version'), entity.use_latest_template_version) and equal(self.param('boot_devices'), [str(dev) for dev in getattr(entity.os.boot, 'devices', [])]) and equal(self.param('instance_type'), get_link_name(self._connection, entity.instance_type), ignore_case=True) and @@ -2349,6 +2355,7 @@ def main(): lease=dict(type='str'), stateless=dict(type='bool'), delete_protected=dict(type='bool'), + custom_emulated_machine=dict(type='str'), force=dict(type='bool', default=False), nics=dict(type='list', default=[]), cloud_init=dict(type='dict'),