Description of problem: Uploading one image into two different datacenters will fail: vars: qcow_url: http://server.com/image.qcow2 template_cluster: template_name: pkubica-rhevm30-rhel62 template_memory: 4GiB template_cpu: 4 template_disk_size: 50GiB roles: - role: oVirt.image-template template_cluster: cluster_in_datacenter1 template_disk_storage: storage_in_datacenter1 - role: oVirt.image-template template_cluster: cluster_in_datacenter2 template_disk_stroage: storage_in_datacenter2 Separate into two different plays will work but template_name must be different to each datacenter. when image doesn't exist in engine: TASK [oVirt.image-template : Fetch storages] ********************** task path: /home/pkubica/.ansible/roles/oVirt.image-template/tasks/qcow2_image.yml:42 ... The full traceback is: Traceback (most recent call last): File "/tmp/ansible_6Xuc6e/ansible_module_ovirt_storage_domains_facts.py", line 87, in main connection = create_connection(auth) File "/tmp/ansible_6Xuc6e/ansible_modlib.zip/ansible/module_utils/ovirt.py", line 146, in create_connection headers=auth.get('headers', None), File "/usr/lib64/python2.7/site-packages/ovirtsdk4/__init__.py", line 303, in __init__ raise Error('The \'url\' parameter is mandatory') Error: The 'url' parameter is mandatory fatal: [engine.example.com]: FAILED! => { "changed": false, "invocation": { "module_args": { "fetch_nested": false, "nested_attributes": [], "pattern": "" } }, "msg": "The 'url' parameter is mandatory" } when image exist in engine: same traceback but in task: TASK [oVirt.image-template : Check if template already exists] Version-Release number of selected component (if applicable): ansible-2.5.1-1.el7.noarch oVirt.image-template (1.1.6) How reproducible: always Steps to Reproduce: see description Actual results: User must separate roles into plays but using variable with role should work. Also specify only qcow_url and template_name to upload multiple images should also work
Verified in ovirt-ansible-image-template-1.1.7-1.el7ev.noarch
This bugzilla is included in oVirt 4.2.4 release, published on June 26th 2018. Since the problem described in this bug report should be resolved in oVirt 4.2.4 release, it has been closed with a resolution of CURRENT RELEASE. If the solution does not work for you, please open a new bug report.