Skip to content

Commit 08ae40d

Browse files
committed
fix: Ignore extra lines in dnf repoquery parsing
Cause: In some RHEL environments, dnf operations write some extra output like "This system is not registered with an entitlement server." Consequence: This breaks the `dnf repoquery` parsing introduced in commit d64b560 and makes the role fail due to the invalid value comparison. Fix: Only consider the last line (which will be the actual version number).
1 parent 588cdb0 commit 08ae40d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tasks/setup-dnf.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
set_fact:
2121
cockpit_packages_dyn_exclude: "{{ ['cockpit-pcp']
2222
if cockpit_packages == 'full'
23-
and __cockpit_bridge_version.stdout is version('326', '>=')
23+
and __cockpit_bridge_version.stdout_lines[-1] is version('326', '>=')
2424
else [] }}"
2525

2626
- name: Ensure Cockpit Web Console packages are installed

0 commit comments

Comments
 (0)