Bug 1885542
| Summary: | Cannot see the current CD image using ovirt_vm_info module | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Virtualization Manager | Reporter: | nijin ashok <nashok> |
| Component: | ovirt-ansible-collection | Assignee: | Martin Necas <mnecas> |
| Status: | CLOSED NEXTRELEASE | QA Contact: | Pavol Brilla <pbrilla> |
| Severity: | low | Docs Contact: | |
| Priority: | low | ||
| Version: | 4.4.2 | CC: | mperina |
| Target Milestone: | ovirt-4.4.3 | Keywords: | ZStream |
| Target Release: | --- | ||
| Hardware: | All | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | ovirt-ansible-collection-1.2.0-0.2 | Doc Type: | No Doc Update |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2020-10-22 14:32:26 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | Infra | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
This change will be part of oVirt Ansible Collection only, it can't be backported to Ansible 2.9.z Merged and will be released in ovirt-ansible-collection 1.2.0 |
Description of problem: Tried with the below task to get the CDROM devices attached to the VM. === - ovirt_vm_info: auth: "{{ ovirt_auth }}" pattern: "centos" all_content: yes fetch_nested: true next_run: false nested_attributes: cdroms,file register: result === The above task will provide the information of persistent cdrom attached to the VM. However, there is no way we can see a cdrom attached during runtime. In Python SDK, we can do this by passing "current=True" as below. === vm_service = vms_service.vm_service(vm.id) cdroms_service = vm_service.cdroms_service() cdrom_device = cdroms_service.list()[0] cdrom_service = cdroms_service.cdrom_service(cdrom_device.id) cdrom = cdrom_service.get(current=True) if cdrom.file is not None: print("VM: %s cdrom: %s" % (vm.name,cdrom.file.id)) === However, it's not possible to pass the "current=True" through Ansible modules. Version-Release number of selected component (if applicable): rhvm-4.4.1.10-0.1.el8ev.noarch How reproducible: 100% Steps to Reproduce: Try using ovirt_vm_info to get the current CD of any VMs. Actual results: Cannot see the current CD image using ovirt_vm_info module Expected results: Provide some solution to view the current CD using Ansible. Additional info: