Skip to content

Commit 03cd6ab

Browse files
authored
Merge branch 'main' into xcover-cap-fix
2 parents 4a58489 + fc03246 commit 03cd6ab

2 files changed

Lines changed: 14 additions & 0 deletions

File tree

e2e-tests/git-checkout-build.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -318,6 +318,11 @@ pipeline:
318318
[ "$status" == "## 1.x...origin/1.x [ahead 2]" ]
319319
# for-cherry-pick.txt should exist as a file
320320
[ -f for-cherry-pick.txt ]
321+
# auto maintenance must be disabled so no fetch (like the unshallow
322+
# fetch for cherry-picks) spawns a detached 'git maintenance run'
323+
# that outlives the pipeline step.
324+
[ "$(git config --get maintenance.auto)" = "false" ]
325+
[ "$(git config --get gc.auto)" = "0" ]
321326
cd ..
322327
rm -R cherry-pick-test
323328

pkg/build/pipelines/git-checkout.yaml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -320,6 +320,15 @@ pipeline:
320320
vr git config --global --add safe.directory "$workdir"
321321
vr git config --global --add safe.directory "$dest_fullpath"
322322
323+
# Never spawn background maintenance: on git >= 2.47 every fetch
324+
# spawns 'git maintenance run --auto --detach', which daemonizes,
325+
# outlives this pipeline step, and races with later steps reading
326+
# .git (e.g. its lock file vanishing mid-tar). The repo is
327+
# ephemeral, so auto maintenance has no value here. gc.auto covers
328+
# code paths that still consult the legacy setting.
329+
vr git config --global maintenance.auto false
330+
vr git config --global gc.auto 0
331+
323332
msg "Attempting git clone with retry (max_retries=$max_retries, initial_backoff=${initial_backoff}s, max_backoff=${max_backoff}s)"
324333
# shellcheck disable=SC2086
325334
retry_with_backoff "$max_retries" "$initial_backoff" "$max_backoff" \

0 commit comments

Comments
 (0)