Skip to content

Commit 38630d2

Browse files
committed
devctr: workaround build failure
Since this is the 3rd time we have issues with git unsafe directories, just assume all directories are safe. This is acceptable since we control all our git dependencies. Signed-off-by: Pablo Barbáchano <[email protected]>
1 parent bcf44d6 commit 38630d2

File tree

3 files changed

+6
-3
lines changed

3 files changed

+6
-3
lines changed

tools/devctr/ctr_gitconfig

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,4 @@
66
# https://github.blog/2022-04-12-git-security-vulnerability-announced/
77

88
[safe]
9-
directory = /firecracker
10-
directory = /firecracker/.git
9+
directory = *

tools/devtool

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -528,10 +528,11 @@ cmd_build() {
528528
function cmd_make_release {
529529
ensure_build_dir
530530
run_devctr \
531-
--user "$(id -u):$(id -g)" \
531+
--privileged \
532532
--workdir "$CTR_FC_ROOT_DIR" \
533533
-- \
534534
./tools/release.sh --libc musl --profile release --make-release
535+
sudo chown -Rc $USER: release*
535536
}
536537

537538
cmd_distclean() {

tools/release.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,9 @@ EOF
9999
done
100100

101101

102+
# workaround until we rebuild devctr
103+
git config --global --replace-all safe.directory '*'
104+
102105
ARCH=$(uname -m)
103106
VERSION=$(get-firecracker-version)
104107
PROFILE_DIR=$(get-profile-dir "$PROFILE")

0 commit comments

Comments
 (0)