Skip to content

Commit

Permalink
Add /root/.local/bin to PATH on Centos Stream 8 in CI
Browse files Browse the repository at this point in the history
This path is missing, therefore tests do not have access to Python
packages installed with `--user`. Local development on Centos Stream
should not be affected as it should be using virtualenv anyway.
  • Loading branch information
happz committed Feb 21, 2023
1 parent 3b6b3c6 commit 1dc5bf8
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion plans/features/advanced.fmf
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ description:
discover:
how: fmf
filter: 'tier: 3'
adjust:
adjust+:
- when: distro == centos-stream, rhel
because: pre-commit is not available from epel, use pip instead
prepare+:
Expand Down
8 changes: 8 additions & 0 deletions plans/features/main.fmf
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,11 @@ prepare+:
# have to run as root to do that, and who's running tmt test suite
# as root?
- pip3 install --user yq || pip3 install yq
- yq --help

adjust+:
- when: distro == centos-stream-8 and trigger == commit
environment+:
# Default PATH, spiked with ~/.local/bin for Python packages installed with --user.
# This is needed on Centos Stream 8 where the user-specific path is not in PATH.
PATH: "/root/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"

0 comments on commit 1dc5bf8

Please sign in to comment.