Verify containers share cargo's package-cache lock: mount the shared volume as CARGO_HOME #43

Merged
eureka merged 3 commits from eureka-substrate/mutants-sccache into main 2026-11-03 01:37:08 +00:00
2 changed files with 2 additions and 4 deletions
Showing only changes of commit 25b98a9699 - Show all commits

CARGO_HOME alone: the image's PATH already holds cargo/bin, and restating it clobbered the test mock's PATH

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Eureka 2026-11-03 01:57:29 +01:00

View file

@ -141,7 +141,7 @@ if [ "$1" = --host ]; then
common=(--label "$YGG_LABEL" "--cpus=${YGG_CPUS:-4}" "--memory=${YGG_MEM:-6g}"
-v "$YGG_WORK:/seed:ro" -v "$D:/cm:ro" -v /etc/machine-id:/etc/machine-id:ro
-v eureka-cargo-home:/cargo-home -v eureka-nuget:/root/.nuget/packages -v eureka-sccache:/sccache
-e BASH_ENV=/tmp/.ygg-bash-env -e CARGO_HOME=/cargo-home -e PATH=/usr/local/cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
-e BASH_ENV=/tmp/.ygg-bash-env -e CARGO_HOME=/cargo-home
-e "WORKDIR=${WORKDIR:-.}" -e "BASE=$BASE" -e "TEST_ARGS=${TEST_ARGS:-}" -e "FILTERS=${FILTERS:-}" -e "CM_NAMES=${CM_NAMES:-}" -e "JOBS=$JOBS"
-e "MIN_TEST_TIMEOUT=$MIN_TEST_TIMEOUT" -e "CONFIRM_TIMEOUT_MULT=$CONFIRM_TIMEOUT_MULT"
-e GIT_CONFIG_COUNT=1 -e GIT_CONFIG_KEY_0=safe.directory -e 'GIT_CONFIG_VALUE_0=*')

View file

@ -407,12 +407,10 @@ else
# on the same disk go first (2026-10-31: three verify jobs held IO pressure at ~75% full).
# Cargo's package-cache lock lives in $CARGO_HOME, so the shared volume is CARGO_HOME itself: a registry-only mount left the
# lock in each container's layer and sibling containers unpacking one crate removed each other's directories (2026-11-03).
# PATH restates the image's; only the rust image needs it.
case $image in eureka-verify-rust:*) cargo_env=(-e CARGO_HOME=/cargo-home -e PATH=/usr/local/cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin) ;; *) cargo_env=() ;; esac
sudo docker run --rm --name "$cname" --label "$label" --cpus="$cpus" --memory="$mem" \
-v "$work:/src" -v /etc/machine-id:/etc/machine-id:ro \
-v eureka-cargo-home:/cargo-home -v eureka-nuget:/root/.nuget/packages \
-v eureka-sccache:/sccache "${cargo_env[@]}" \
-v eureka-sccache:/sccache -e CARGO_HOME=/cargo-home \
-e BASH_ENV=/tmp/.ygg-bash-env ${nonce:+-e YGG_NONCE=$nonce} \
-e GIT_CONFIG_COUNT=1 -e GIT_CONFIG_KEY_0=safe.directory -e GIT_CONFIG_VALUE_0='*' \
$docker_args \