You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Trying to rename a template with Windows as guest OS.
This fails with Cannot edit Template. TPM device is required by the guest OS.
I'm not changing anything related to TPM, I only want to rename the template.
COMPONENT NAME
ovirt_template
STEPS TO REPRODUCE
- name: Lookup id for latest templateovirt.ovirt.ovirt_template_info:
auth: "{{ ovirt_auth }}"pattern: name=windows2025*_latestregister: result
- name: Rename latest template to previousovirt.ovirt.ovirt_template:
auth: "{{ ovirt_auth }}"id: "{{ result.ovirt_templates[0].id }}"name: windows2025-template_previous
EXPECTED RESULTS
Template windows2025-template_latest is renamed to windows2025-template_previous
ACTUAL RESULTS
The full traceback is:
Traceback (most recent call last):
File "/tmp/ansible_ovirt.ovirt.ovirt_template_payload_twnd0vo1/ansible_ovirt.ovirt.ovirt_template_payload.zip/ansible_collections/ovirt/ovirt/plugins/modules/ovirt_template.py", line 1056, in main
File "/tmp/ansible_ovirt.ovirt.ovirt_template_payload_twnd0vo1/ansible_ovirt.ovirt.ovirt_template_payload.zip/ansible_collections/ovirt/ovirt/plugins/module_utils/ovirt.py", line 648, in create
updated_entity = entity_service.update(
^^^^^^^^^^^^^^^^^^^^^^
File "/home/gregory/.local/lib/python3.11/site-packages/ovirtsdk4/services.py", line 29215, in update
return self._internal_update(template, headers, query, wait)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/gregory/.local/lib/python3.11/site-packages/ovirtsdk4/service.py", line 253, in _internal_update
return future.wait() if wait else future
^^^^^^^^^^^^^
File "/home/gregory/.local/lib/python3.11/site-packages/ovirtsdk4/service.py", line 55, in wait
return self._code(response)
^^^^^^^^^^^^^^^^^^^^
File "/home/gregory/.local/lib/python3.11/site-packages/ovirtsdk4/service.py", line 250, in callback
self._check_fault(response)
File "/home/gregory/.local/lib/python3.11/site-packages/ovirtsdk4/service.py", line 132, in _check_fault
self._raise_error(response, body)
File "/home/gregory/.local/lib/python3.11/site-packages/ovirtsdk4/service.py", line 118, in _raise_error
raise error
ovirtsdk4.Error: Fault reason is "Operation Failed". Fault detail is "[Cannot edit Template. TPM device is required by the guest OS.]". HTTP response code is 409.
fatal: [localhost]: FAILED! => {
"changed": false,
"invocation": {
"module_args": {
"allow_partial_import": null,
"ballooning_enabled": null,
"bios_type": null,
"boot_menu": null,
"clone_name": null,
"clone_permissions": null,
"cloud_init": null,
"cloud_init_nics": [],
"cluster": null,
"cluster_mappings": [],
"cpu_profile": null,
"description": null,
"domain_mappings": [],
"exclusive": null,
"export_domain": null,
"fetch_nested": false,
"id": "8d95ec46-285f-4a66-aa24-e59c50dcdd8c",
"image_disk": null,
"image_provider": null,
"io_threads": null,
"kvm": null,
"memory": null,
"memory_guaranteed": null,
"memory_max": null,
"name": "windows2025-template_previous",
"nested_attributes": [],
"nics": [],
"operating_system": null,
"poll_interval": 3,
"role_mappings": [],
"seal": null,
"smartcard_enabled": null,
"soundcard_enabled": null,
"sso": null,
"state": "present",
"storage_domain": null,
"sysprep": null,
"template_image_disk_name": null,
"timeout": 180,
"timezone": null,
"usb_support": null,
"version": null,
"vm": null,
"vnic_profile_mappings": [],
"wait": true
}
},
"msg": "Fault reason is \"Operation Failed\". Fault detail is \"[Cannot edit Template. TPM device is required by the guest OS.]\". HTTP response code is 409."
}
The text was updated successfully, but these errors were encountered:
SUMMARY
Trying to rename a template with Windows as guest OS.
This fails with
Cannot edit Template. TPM device is required by the guest OS
.I'm not changing anything related to TPM, I only want to rename the template.
COMPONENT NAME
ovirt_template
STEPS TO REPRODUCE
EXPECTED RESULTS
Template windows2025-template_latest is renamed to windows2025-template_previous
ACTUAL RESULTS
The text was updated successfully, but these errors were encountered: