From c5c78ab045b964fbb048d8a380533a649ad6f5ff Mon Sep 17 00:00:00 2001 From: Ondra Machacek Date: Sat, 10 Mar 2018 10:41:23 +0100 Subject: [PATCH] ovirt_vms: Pass correct VM entity to create method (#37249) --- lib/ansible/modules/cloud/ovirt/ovirt_vms.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/ansible/modules/cloud/ovirt/ovirt_vms.py b/lib/ansible/modules/cloud/ovirt/ovirt_vms.py index ce2b4702b21..6cc40de787c 100644 --- a/lib/ansible/modules/cloud/ovirt/ovirt_vms.py +++ b/lib/ansible/modules/cloud/ovirt/ovirt_vms.py @@ -1898,6 +1898,7 @@ def main(): vms_module.changed = import_vm(module, connection) ret = vms_module.create( + entity=vm, result_state=otypes.VmStatus.DOWN if vm is None else None, clone=module.params['clone'], clone_permissions=module.params['clone_permissions'], @@ -1920,6 +1921,7 @@ def main(): ) elif state == 'suspended': vms_module.create( + entity=vm, result_state=otypes.VmStatus.DOWN if vm is None else None, clone=module.params['clone'], clone_permissions=module.params['clone_permissions'],