Skip to content

Commit 1cc2348

Browse files
committed
fix(ci): preserve VM runtime for E2E
The Rust cache restores target/ after VM runtime artifacts are staged, overwriting target/vm-runtime-compressed before openshell-driver-vm is built. Stage the compressed runtime outside target and pass that location through OPENSHELL_VM_RUNTIME_COMPRESSED_DIR so build.rs can embed the supervisor. Also locate the Helm split-ownership test repository root from the script path rather than git rev-parse. The test runs in a container where the GitHub checkout can be owned by a different UID and rejected as dubious ownership. Signed-off-by: Dhiraj Bokde <dbokde@nvidia.com>
1 parent 53df022 commit 1cc2348

2 files changed

Lines changed: 13 additions & 13 deletions

File tree

.github/workflows/build-vm-driver.yml

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -70,28 +70,28 @@ jobs:
7070
- name: Compress Linux VM runtime
7171
if: runner.os == 'Linux'
7272
run: |
73-
install -d target/vm-runtime-compressed
74-
zstd -19 -T0 result/libkrun.so -o target/vm-runtime-compressed/libkrun.so.zst
75-
zstd -19 -T0 result/libkrunfw.so.5 -o target/vm-runtime-compressed/libkrunfw.so.5.zst
76-
zstd -19 -T0 result/gvproxy -o target/vm-runtime-compressed/gvproxy.zst
77-
zstd -19 -T0 result/umoci -o target/vm-runtime-compressed/umoci.zst
73+
install -d .e2e/vm-runtime-compressed
74+
zstd -19 -T0 result/libkrun.so -o .e2e/vm-runtime-compressed/libkrun.so.zst
75+
zstd -19 -T0 result/libkrunfw.so.5 -o .e2e/vm-runtime-compressed/libkrunfw.so.5.zst
76+
zstd -19 -T0 result/gvproxy -o .e2e/vm-runtime-compressed/gvproxy.zst
77+
zstd -19 -T0 result/umoci -o .e2e/vm-runtime-compressed/umoci.zst
7878
7979
- name: Compress macOS VM runtime
8080
if: runner.os == 'macOS'
8181
run: |
82-
install -d target/vm-runtime-compressed
83-
zstd -19 -T0 result/libkrun.dylib -o target/vm-runtime-compressed/libkrun.dylib.zst
84-
zstd -19 -T0 result/libkrunfw.5.dylib -o target/vm-runtime-compressed/libkrunfw.5.dylib.zst
85-
zstd -19 -T0 result/gvproxy -o target/vm-runtime-compressed/gvproxy.zst
86-
zstd -19 -T0 result/umoci -o target/vm-runtime-compressed/umoci.zst
82+
install -d .e2e/vm-runtime-compressed
83+
zstd -19 -T0 result/libkrun.dylib -o .e2e/vm-runtime-compressed/libkrun.dylib.zst
84+
zstd -19 -T0 result/libkrunfw.5.dylib -o .e2e/vm-runtime-compressed/libkrunfw.5.dylib.zst
85+
zstd -19 -T0 result/gvproxy -o .e2e/vm-runtime-compressed/gvproxy.zst
86+
zstd -19 -T0 result/umoci -o .e2e/vm-runtime-compressed/umoci.zst
8787
8888
- name: Add openshell-sandbox to VM runtime
89-
run: zstd -19 -T0 sandbox/openshell-sandbox -o target/vm-runtime-compressed/openshell-sandbox.zst
89+
run: zstd -19 -T0 sandbox/openshell-sandbox -o .e2e/vm-runtime-compressed/openshell-sandbox.zst
9090

9191
- name: Build openshell-driver-vm
9292
uses: ./.github/actions/build-rust-binary
9393
env:
94-
OPENSHELL_VM_RUNTIME_COMPRESSED_DIR: ${{ github.workspace }}/target/vm-runtime-compressed
94+
OPENSHELL_VM_RUNTIME_COMPRESSED_DIR: ${{ github.workspace }}/.e2e/vm-runtime-compressed
9595
with:
9696
package: openshell-driver-vm
9797
binary: openshell-driver-vm

deploy/helm/test-split-ownership.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
set -euo pipefail
66

7-
repo_root="$(git rev-parse --show-toplevel)"
7+
repo_root="$(cd "$(dirname "${BASH_SOURCE[0]}")/../.." && pwd -P)"
88
work_dir="$(mktemp -d)"
99
trap 'rm -rf "${work_dir}"' EXIT
1010

0 commit comments

Comments
 (0)