mirror of
https://pagure.io/fedora-qa/os-autoinst-distri-fedora.git
synced 2025-08-18 21:35:45 +00:00
Fix CI for Fedora 41 (dnf 5)
See https://pagure.io/fedora-project-config/issue/340 and https://github.com/ansible/ansible/issues/84206 . We need to force install python3-libdnf5 or ansible can't manage packages. Signed-off-by: Adam Williamson <awilliam@redhat.com>
This commit is contained in:
parent
10a5429ea8
commit
c2e1960eee
16
ci/dnf-dependency.yaml
Normal file
16
ci/dnf-dependency.yaml
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
# See https://github.com/ansible/ansible/issues/84206 for the background on this
|
||||||
|
# When the server is on ansible >= 2.19 things should just work, but ours are
|
||||||
|
# not (RHEL 9 has 2.14, RHEL 8 has 2.15, as I write this)
|
||||||
|
|
||||||
|
- name: Ensure that python3-libdnf5 is installed
|
||||||
|
block:
|
||||||
|
- name: Check whether python3-libdnf5 is installed
|
||||||
|
ansible.builtin.command: "rpm -q python3-libdnf5"
|
||||||
|
register: p3dnf5
|
||||||
|
failed_when: "1 != 1"
|
||||||
|
changed_when: "1 != 1"
|
||||||
|
check_mode: no
|
||||||
|
|
||||||
|
- name: Install python3-libdnf5 with direct dnf command
|
||||||
|
ansible.builtin.command: "dnf -y install python3-libdnf5"
|
||||||
|
when: "p3dnf5.rc != 0"
|
@ -1,5 +1,8 @@
|
|||||||
- hosts: all
|
- hosts: all
|
||||||
tasks:
|
tasks:
|
||||||
|
- name: Include dnf dependency workaround task
|
||||||
|
ansible.builtin.include_tasks:
|
||||||
|
file: dnf-dependency.yaml
|
||||||
- name: Install required packages
|
- name: Install required packages
|
||||||
package:
|
package:
|
||||||
name: ['os-autoinst', 'perl-Test-Strict', 'perl-Test-Harness', 'perl-JSON', 'perl-REST-Client', 'perl-Code-TidyAll']
|
name: ['os-autoinst', 'perl-Test-Strict', 'perl-Test-Harness', 'perl-JSON', 'perl-REST-Client', 'perl-Code-TidyAll']
|
||||||
|
@ -1,5 +1,8 @@
|
|||||||
- hosts: all
|
- hosts: all
|
||||||
tasks:
|
tasks:
|
||||||
|
- name: Include dnf dependency workaround task
|
||||||
|
ansible.builtin.include_tasks:
|
||||||
|
file: dnf-dependency.yaml
|
||||||
- name: Ensure tox is installed
|
- name: Ensure tox is installed
|
||||||
include_role:
|
include_role:
|
||||||
name: ensure-tox
|
name: ensure-tox
|
||||||
|
Loading…
Reference in New Issue
Block a user