build.sh: carry FP6IMG_NO_CROSSDIRECT across the su re-exec
Some checks failed
image / image (push) Has been cancelled

su scrubs the environment, so the escape hatch from the previous commit
never reached the build user (verified: libcamera still built crossdirect
and failed identically).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Jorijn van der Graaf 2026-08-24 05:39:11 +02:00
commit 1c275d87d2

View file

@ -72,7 +72,8 @@ if [ "$(id -u)" = 0 ]; then
# would poison the next podman invocation's cwd)
install -d -o build dist
find dist -mindepth 1 -delete
exec su build -c "sh -eu '$PWD/build.sh'"
# su scrubs the environment — carry the knobs that matter across it
exec su build -c "FP6IMG_NO_CROSSDIRECT='${FP6IMG_NO_CROSSDIRECT:-}' sh -eu '$PWD/build.sh'"
fi
# git hosts occasionally hiccup (our forgejo lives on a small VM that also