From 5fc45d04cc1eeb16be7808b1f12fd6fe48744bef Mon Sep 17 00:00:00 2001 From: Samuel K Date: Sun, 26 Jul 2026 13:46:35 -0500 Subject: [PATCH 1/3] ci: run prebuilt e2e test binary in integration matrix Compile the e2e suite once in build-cli and run the resulting binary in the integration matrix legs instead of downloading modules and recompiling on every fan-out job. Disable the now-unused Go module cache on those jobs. --- .github/workflows/pr-ci.yml | 45 ++++++++++++++++++++++++++++++++----- 1 file changed, 40 insertions(+), 5 deletions(-) diff --git a/.github/workflows/pr-ci.yml b/.github/workflows/pr-ci.yml index 4811aa33a..50a246ddf 100644 --- a/.github/workflows/pr-ci.yml +++ b/.github/workflows/pr-ci.yml @@ -118,6 +118,24 @@ jobs: name: devsy-${{ steps.os.outputs.runner_os }} path: dist/devsy-${{ steps.os.outputs.runner_os }}_*/devsy-${{ steps.os.outputs.runner_os }}-* + - name: build e2e test binary + if: matrix.runner == 'ubuntu-22.04' || matrix.runner == 'windows-latest' + shell: bash + working-directory: ./e2e + run: | + OUT="e2e.test" + if [ "${{ runner.os }}" == "Windows" ]; then + OUT="e2e.test.exe" + fi + go test -c -o "$OUT" ./ + + - name: upload e2e test binary + if: matrix.runner == 'ubuntu-22.04' || matrix.runner == 'windows-latest' + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7 + with: + name: e2e-test-${{ steps.os.outputs.runner_os }} + path: ./e2e/e2e.test* + licenses: name: Third-party licenses needs: [changes, precommit, lint] @@ -167,6 +185,7 @@ jobs: uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7 with: go-version-file: go.mod + cache: false - name: get operating system lowercase id: os @@ -182,6 +201,12 @@ jobs: path: ${{ runner.temp }}/devsy-bin/ merge-multiple: true + - name: download e2e test binary + uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8 + with: + name: e2e-test-${{ steps.os.outputs.runner_os }} + path: ./e2e/ + - name: setup executable shell: bash working-directory: ./e2e @@ -191,6 +216,7 @@ jobs: mkdir -p ./bin/ find "$TEMP_DIR/devsy-bin/" -type f -name "devsy-*" -exec cp {} ./bin \; find ./bin -name "devsy-*" -exec chmod +x {} \; + chmod +x ./e2e.test ls -R ./bin/ - name: run test @@ -201,7 +227,7 @@ jobs: GH_ACCESS_TOKEN: ${{ github.token }} GH_CREDENTIAL_USERNAME: x-access-token run: | - go test -v -ginkgo.v -timeout 1500s --ginkgo.label-filter="${{ matrix.label }}" + ./e2e.test -test.v -ginkgo.v -test.timeout 1500s --ginkgo.label-filter="${{ matrix.label }}" integration-tests: name: Test ${{ matrix.label }}${{ matrix.install-podman && format(' ({0})', matrix.install-podman) || '' }} on ${{ matrix.runner }} @@ -432,6 +458,7 @@ jobs: uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7 with: go-version-file: go.mod + cache: false - name: install gnupg2 if: runner.os == 'Linux' && (matrix.requires-secret == false || needs.can-read-secret.outputs.secret-set == 'true') @@ -464,6 +491,13 @@ jobs: path: ${{ runner.temp }}/devsy-bin/ merge-multiple: true + - name: download e2e test binary + if: matrix.requires-secret == false || needs.can-read-secret.outputs.secret-set == 'true' + uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8 + with: + name: e2e-test-${{ steps.os.outputs.runner_os }} + path: ./e2e/ + # e2e expects executable to have name defined in e2e/framework/framework.go - name: setup executable if: matrix.requires-secret == false || needs.can-read-secret.outputs.secret-set == 'true' @@ -479,6 +513,9 @@ jobs: mkdir -p ./bin/ find "$TEMP_DIR/devsy-bin/" -type f -name "devsy-*" -exec cp {} ./bin \; find ./bin -name "devsy-*" -exec chmod +x {} \; + if [ "${{ runner.os }}" == "Linux" ]; then + chmod +x ./e2e.test + fi ls -R ./bin/ - name: generate uuid @@ -607,17 +644,15 @@ jobs: KUBECONFIG="${KUBECONFIG:-$HOME/.kube/config}" \ ${DOCKER_HOST:+DOCKER_HOST="${DOCKER_HOST}"} \ PATH="${PATH}" \ - GOROOT="${GOROOT}" \ - go test -v -ginkgo.v -timeout 1500s --ginkgo.label-filter="${{ matrix.label }}" + ./e2e.test -test.v -ginkgo.v -test.timeout 1500s --ginkgo.label-filter="${{ matrix.label }}" else GH_USERNAME="${GH_USERNAME}" \ GH_ACCESS_TOKEN="${GH_ACCESS_TOKEN}" \ GH_CREDENTIAL_USERNAME="${GH_CREDENTIAL_USERNAME}" \ KUBECONFIG="${KUBECONFIG:-$HOME/.kube/config}" \ PATH="${PATH}" \ - GOROOT="${GOROOT}" \ DOCKER_HOST="npipe:////./pipe/podman-machine-default" \ - go test -v -ginkgo.v -timeout 1500s --ginkgo.label-filter="${{ matrix.label }}" + ./e2e.test.exe -test.v -ginkgo.v -test.timeout 1500s --ginkgo.label-filter="${{ matrix.label }}" fi - name: verify docker is installed From 86c4b1c8c08605519023e4609877b635a2dc23bd Mon Sep 17 00:00:00 2001 From: Samuel K Date: Sun, 26 Jul 2026 13:50:00 -0500 Subject: [PATCH 2/3] ci: drop unused Go toolchain setup from e2e fan-out jobs --- .github/workflows/pr-ci.yml | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/.github/workflows/pr-ci.yml b/.github/workflows/pr-ci.yml index 50a246ddf..961631ccc 100644 --- a/.github/workflows/pr-ci.yml +++ b/.github/workflows/pr-ci.yml @@ -181,12 +181,6 @@ jobs: steps: - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 - - name: setup Go - uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7 - with: - go-version-file: go.mod - cache: false - - name: get operating system lowercase id: os shell: bash @@ -453,13 +447,6 @@ jobs: - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 if: matrix.requires-secret == false || needs.can-read-secret.outputs.secret-set == 'true' - - name: setup Go - if: matrix.requires-secret == false || needs.can-read-secret.outputs.secret-set == 'true' - uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7 - with: - go-version-file: go.mod - cache: false - - name: install gnupg2 if: runner.os == 'Linux' && (matrix.requires-secret == false || needs.can-read-secret.outputs.secret-set == 'true') run: sudo apt-get install -y gnupg2 From 92a3343ed82540547705bd6b501812ebda1ecff5 Mon Sep 17 00:00:00 2001 From: Samuel K Date: Sun, 26 Jul 2026 15:05:54 -0500 Subject: [PATCH 3/3] ci: build e2e test binary with CGO disabled for portability --- .github/workflows/pr-ci.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/pr-ci.yml b/.github/workflows/pr-ci.yml index 961631ccc..5d4698886 100644 --- a/.github/workflows/pr-ci.yml +++ b/.github/workflows/pr-ci.yml @@ -122,6 +122,8 @@ jobs: if: matrix.runner == 'ubuntu-22.04' || matrix.runner == 'windows-latest' shell: bash working-directory: ./e2e + env: + CGO_ENABLED: 0 run: | OUT="e2e.test" if [ "${{ runner.os }}" == "Windows" ]; then