File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -6,8 +6,18 @@ dnf install -y git-core
66git clone --depth=1 " {{ .RunnerImageRepo }}" /opt/action-runner-image-pz
77
88cd /opt/action-runner-image-pz
9- # Allow build to continue past flaky upstream test failures
9+ # Snapshot the runner binary as soon as it is built; a later installer
10+ # failure (e.g. Docker GPG key) can trigger cleanup that deletes it.
11+ (while [ ! -f /opt/runner-cache/config.sh ]; do sleep 10; done
12+ cp -a /opt/runner-cache /opt/runner-backup) &
13+ WATCHER_PID=$!
14+
1015bash -c ' . scripts/vm.sh rhel 9 minimal --skip-snap-lxd' || true
16+ kill $WATCHER_PID 2> /dev/null || true
17+
18+ if [ ! -f /opt/runner-cache/config.sh ] && [ -d /opt/runner-backup ]; then
19+ mv /opt/runner-backup /opt/runner-cache
20+ fi
1121
1222if [ ! -f /opt/runner-cache/config.sh ]; then
1323 echo " Runner binary not found after build — check build logs" >&2
Original file line number Diff line number Diff line change @@ -6,8 +6,18 @@ apt-get update -y && apt-get install -y software-properties-common
66git clone --depth=1 " {{ .RunnerImageRepo }}" /opt/action-runner-image-pz
77
88cd /opt/action-runner-image-pz
9- # Allow build to continue past flaky upstream test failures
9+ # Snapshot the runner binary as soon as it is built; a later installer
10+ # failure (e.g. Docker GPG key) can trigger cleanup that deletes it.
11+ (while [ ! -f /opt/runner-cache/config.sh ]; do sleep 10; done
12+ cp -a /opt/runner-cache /opt/runner-backup) &
13+ WATCHER_PID=$!
14+
1015bash -c ' . scripts/vm.sh ubuntu 22.04 minimal --skip-snap-lxd' || true
16+ kill $WATCHER_PID 2> /dev/null || true
17+
18+ if [ ! -f /opt/runner-cache/config.sh ] && [ -d /opt/runner-backup ]; then
19+ mv /opt/runner-backup /opt/runner-cache
20+ fi
1121
1222if [ ! -f /opt/runner-cache/config.sh ]; then
1323 echo " Runner binary not found after build — check build logs" >&2
You can’t perform that action at this time.
0 commit comments