From 018f3ecf7e2100d873391a354086f17469514ecf Mon Sep 17 00:00:00 2001 From: Ronelle Landy Date: Thu, 6 Jan 2022 18:16:25 -0500 Subject: [PATCH] Remove fwupd-redfish.conf file from overcloud images Right now, the fwupd package is attempting to load the module ipmi_si and this one is failing to be load. This patch customize the qcow2 image removing the fwupd-redfish.conf that is causing this problem. It is, right now hard to just exclude the package because of the dependences, as well as downgrade, because of how the repositories are configured in the image, so the best approach to temporarly solve the problem is in this way with virt-customize. Related-Bug: #1956441 Signed-off-by: Amol Kahat Change-Id: I07b2344f85c6997c10c3e50a86ba8e16dfcb1355 --- roles/oooci-build-images/tasks/main.yaml | 18 +++++++++++ .../tasks/remove_redfish.yaml | 31 +++++++++++++++++++ 2 files changed, 49 insertions(+) create mode 100644 roles/oooci-build-images/tasks/remove_redfish.yaml diff --git a/roles/oooci-build-images/tasks/main.yaml b/roles/oooci-build-images/tasks/main.yaml index 9dc3e4c2a..7769f56a3 100644 --- a/roles/oooci-build-images/tasks/main.yaml +++ b/roles/oooci-build-images/tasks/main.yaml @@ -108,6 +108,15 @@ - when: overcloud_stat_result.stat.exists|bool block: + # TODO akahat Remove once lp https://bugs.launchpad.net/tripleo/+bug/1956441 fixed. + - name: Include remove_redfish.yaml + include_tasks: remove_redfish.yaml + args: + apply: + become: true + vars: + overcloud_image_customize: overcloud-full.qcow2 + - name: overcloud-full archive: path: @@ -127,6 +136,15 @@ - when: overcloud_hardened_uefi_stat_result.stat.exists|bool block: + # TODO akahat Remove once lp https://bugs.launchpad.net/tripleo/+bug/1956441 fixed. + - name: Include remove_redfish.yaml + include_tasks: remove_redfish.yaml + args: + apply: + become: true + vars: + overcloud_image_customize: overcloud-hardened-uefi-full.qcow2 + - name: Move image to {{ ansible_user_dir }} command: "mv {{ workspace }}/overcloud-hardened-uefi-full.qcow2 {{ ansible_user_dir }}" when: workspace != ansible_user_dir diff --git a/roles/oooci-build-images/tasks/remove_redfish.yaml b/roles/oooci-build-images/tasks/remove_redfish.yaml new file mode 100644 index 000000000..7d81bb04d --- /dev/null +++ b/roles/oooci-build-images/tasks/remove_redfish.yaml @@ -0,0 +1,31 @@ +--- +- name: Install libguestfs packages + package: + name: + - libvirt + - libvirt-daemon + - qemu-kvm-common + - qemu-kvm + - libvirt-daemon-kvm + - libvirt-daemon-driver-network + - libvirt-daemon-driver-qemu + - libguestfs-tools + - libguestfs-tools-c + state: present + +- name: Start libvirtd service + service: + name: libvirtd + state: started + enabled: true + +# TODO akahat Remove once lp https://bugs.launchpad.net/tripleo/+bug/1956441 fixed. +- name: Remove fwupd-redfish.conf file from {{ overcloud_image_customize }} + shell: | + virt-customize -a {{ overcloud_image_customize }} --run-command 'rm -f /usr/lib/modules-load.d/fwupd-redfish.conf' + args: + chdir: "{{ workspace }}" + environment: + LIBGUESTFS_BACKEND_SETTINGS: force_tcg + LIBGUESTFS_BACKEND: direct + changed_when: true