From 1f23f607aff5effb0e3ab9d4b00ba59adde60ea4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20=C5=BBygowski?= Date: Thu, 14 May 2026 12:54:47 +0200 Subject: [PATCH] build.sh: Fix permissions when building with GH actions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The GH runners have UID 1001, while user coreboot in SDK has id 1000. This creates a mismatch of IDs and causes permission problems when mounting coreboot git repository under /home/coreboot/coreboot in the container, because the /home/coreboot is a HOME directory of different user. To fix the problem, move the mountpoint to a "neutral" place, where permissions should not be a an issue. The /build directory is chosen so that it does not collide with any HOME directory or system directory. Upstream-Status: Inappropriate [Dasharo CI] Signed-off-by: Michał Żygowski --- build.sh | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/build.sh b/build.sh index 3218276719..81ac346079 100755 --- a/build.sh +++ b/build.sh @@ -49,10 +49,11 @@ BUILD_TIMELESS=${BUILD_TIMELESS:-0} AIRGAP=${AIRGAP:-0} function sdk_run { - docker run --rm -t -u $UID -v $PWD:/home/coreboot/coreboot \ + docker run --rm -t -u $UID \ + -v $PWD:/build/coreboot \ -v $HOME/.ssh:/home/coreboot/.ssh \ -e BUILD_TIMELESS=${BUILD_TIMELESS} \ - -w /home/coreboot/coreboot ${DASHARO_SDK} \ + -w /build/coreboot ${DASHARO_SDK} \ "$@" } @@ -222,11 +223,9 @@ function build_novacustom_v5x0tu { wget -O novacustom_v54x_mtl_v0.9.0.rom https://dl.3mdeb.com/open-source-firmware/Dasharo/novacustom_v54x_mtl/v0.9.0/novacustom_v54x_mtl_v0.9.0.rom # Extract and transfer LAN ROM blob - docker run --rm -t -u $UID -v $PWD:/home/coreboot/coreboot \ - -v $HOME/.ssh:/home/coreboot/.ssh \ - -w /home/coreboot/coreboot ${DASHARO_SDK} \ - /bin/bash -c "make -C util/cbfstool && \ - util/cbfstool/cbfstool novacustom_v54x_mtl_v0.9.0.rom extract -r COREBOOT -f payload -n fallback/payload -m x86" + sdk_run /bin/bash -c "make -C util/cbfstool && \ + util/cbfstool/cbfstool novacustom_v54x_mtl_v0.9.0.rom extract \ + -r COREBOOT -f payload -n fallback/payload -m x86" ./uefiextract payload DEB917C0-C56A-4860-A05B-BF2F22EBB717 mkdir -p 3rdparty/blobs/mainboard/novacustom/mtl-h