Skip to content

Commit 896887d

Browse files
committed
ci(os): use distro Python for linkage checks
1 parent 7f049b3 commit 896887d

1 file changed

Lines changed: 8 additions & 1 deletion

File tree

.github/workflows/mkosi-build.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,8 +103,15 @@ jobs:
103103
test -z "${DSTACK_DEV_CACHE_DIR:-}"
104104
# GitHub-hosted Ubuntu runners restrict unprivileged user namespaces.
105105
# Run mkosi as root instead of weakening the runner's AppArmor policy.
106+
# Keep setup-python out of the build PATH because Ubuntu's lddtree
107+
# expects the distro Python and its python3-pyelftools module.
108+
ci_bin="$RUNNER_TEMP/mkosi-ci-bin"
109+
mkdir -p "$ci_bin"
110+
ln -s "$(command -v mkosi)" "$ci_bin/mkosi"
111+
ln -s "$(command -v nitro-tpm-pcr-compute)" \
112+
"$ci_bin/nitro-tpm-pcr-compute"
106113
sudo --set-home env \
107-
"PATH=$PATH" \
114+
"PATH=$ci_bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" \
108115
"SOURCE_DATE_EPOCH=$SOURCE_DATE_EPOCH" \
109116
"DSTACK_MR_BIN=$DSTACK_MR_BIN" \
110117
"JOBS=$JOBS" \

0 commit comments

Comments
 (0)