Skip to content

Commit

Permalink
Install util-linux into the target container
Browse files Browse the repository at this point in the history
The util-linug RPM is not installed automatically as a dependency
when:
  * upgrading 9 -> 10
  * or when dnf is configured to: install_weak_deps=False
    (affecting all upgrade paths)

Missing util-linux package leads to error due to missing `su` command
inside the container.

jira: https://issues.redhat.com/browse/RHEL-43978
  • Loading branch information
Rezney committed Jul 18, 2024
1 parent 3ab53e7 commit da6f024
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ def _consume_data(self):
It doesn't consume TargetRepositories, which are consumed in the
own function.
"""
self.packages = {'dnf', 'dnf-command(config-manager)'}
self.packages = {'dnf', 'dnf-command(config-manager)', 'util-linux'}
self.files = []
_cftuples = set()

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1001,7 +1001,7 @@ def test_consume_data(monkeypatch, raised, no_rhsm, testdata):
# do not write never into testdata inside the test !!
xfs = testdata.xfs
custom_repofiles = testdata.custom_repofiles
_exp_pkgs = {'dnf', 'dnf-command(config-manager)'}
_exp_pkgs = {'dnf', 'dnf-command(config-manager)', 'util-linux'}
_exp_files = []

def _get_pkgs(msg):
Expand Down
2 changes: 1 addition & 1 deletion repos/system_upgrade/common/libraries/tests/test_rpms.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ def test_get_leapp_packages(major_version, component, result, monkeypatch):
r"component nosuchcomponent is unknown, available choices are \['cockpit', 'framework', 'repository', 'tools']")
),
('nosuchversion', "framework",
(ValueError, r"major_version nosuchversion is unknown, available choices are \['7', '8']")),
(ValueError, r"major_version nosuchversion is unknown, available choices are \['7', '8', '9']")),
('nosuchversion', False,
(ValueError, r"At least one component must be specified when calling this function,"
r" available choices are \['cockpit', 'framework', 'repository', 'tools']")),
Expand Down
Empty file.

0 comments on commit da6f024

Please sign in to comment.