Skip to content

Commit 878d186

Browse files
committed
test(ci): add label-gated upgrade qualification
Signed-off-by: Evan Lezar <[email protected]>
1 parent b92880c commit 878d186

3 files changed

Lines changed: 70 additions & 8 deletions

File tree

‎.github/workflows/branch-e2e.yml‎

Lines changed: 56 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ jobs:
2626
run_integration: ${{ steps.labels.outputs.run_core_e2e }}
2727
run_core_e2e: ${{ steps.labels.outputs.run_core_e2e }}
2828
run_gpu_e2e: ${{ steps.labels.outputs.run_gpu_e2e }}
29+
run_integration_upgrades: ${{ steps.labels.outputs.run_integration_upgrades }}
2930
run_kubernetes_ha_e2e: ${{ steps.labels.outputs.run_kubernetes_ha_e2e }}
3031
run_kubernetes_credential_drivers_e2e: ${{ steps.labels.outputs.run_kubernetes_credential_drivers_e2e }}
3132
run_any_e2e: ${{ steps.labels.outputs.run_any_e2e }}
@@ -47,6 +48,7 @@ jobs:
4748
push)
4849
run_core_e2e="$(jq -r 'index("test:e2e") != null' <<< "$LABELS_JSON")"
4950
run_gpu_e2e="$(jq -r 'index("test:e2e-gpu") != null' <<< "$LABELS_JSON")"
51+
run_integration_upgrades="$(jq -r 'index("test:upgrade") != null' <<< "$LABELS_JSON")"
5052
run_kubernetes_ha_e2e=false
5153
run_kubernetes_credential_drivers_e2e=false
5254
;;
@@ -56,17 +58,19 @@ jobs:
5658
# and ejects the PR. HA stays off until stable.
5759
run_core_e2e=true
5860
run_gpu_e2e=true
61+
run_integration_upgrades=false
5962
run_kubernetes_ha_e2e=false
6063
run_kubernetes_credential_drivers_e2e=false
6164
;;
6265
*)
6366
run_core_e2e=true
6467
run_gpu_e2e=true
68+
run_integration_upgrades=false
6569
run_kubernetes_ha_e2e=false
6670
run_kubernetes_credential_drivers_e2e=false
6771
;;
6872
esac
69-
if [ "$run_core_e2e" = "true" ] || [ "$run_gpu_e2e" = "true" ] || [ "$run_kubernetes_ha_e2e" = "true" ] || [ "$run_kubernetes_credential_drivers_e2e" = "true" ]; then
73+
if [ "$run_core_e2e" = "true" ] || [ "$run_gpu_e2e" = "true" ] || [ "$run_integration_upgrades" = "true" ] || [ "$run_kubernetes_ha_e2e" = "true" ] || [ "$run_kubernetes_credential_drivers_e2e" = "true" ]; then
7074
run_any_e2e=true
7175
else
7276
run_any_e2e=false
@@ -75,6 +79,7 @@ jobs:
7579
{
7680
echo "run_core_e2e=$run_core_e2e"
7781
echo "run_gpu_e2e=$run_gpu_e2e"
82+
echo "run_integration_upgrades=$run_integration_upgrades"
7883
echo "run_kubernetes_ha_e2e=$run_kubernetes_ha_e2e"
7984
echo "run_kubernetes_credential_drivers_e2e=$run_kubernetes_credential_drivers_e2e"
8085
echo "run_any_e2e=$run_any_e2e"
@@ -89,6 +94,7 @@ jobs:
8994
timeout-minutes: 5
9095
outputs:
9196
cargo: ${{ steps.version.outputs.cargo }}
97+
deb: ${{ steps.version.outputs.deb }}
9298
steps:
9399
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
94100
with:
@@ -99,7 +105,11 @@ jobs:
99105
id: version
100106
run: |
101107
cargo="$(python3 tasks/scripts/release.py get-version --cargo)"
102-
echo "cargo=$cargo" >> "$GITHUB_OUTPUT"
108+
deb="$(python3 tasks/scripts/release.py get-version --dev --deb)"
109+
{
110+
echo "cargo=$cargo"
111+
echo "deb=$deb"
112+
} >> "$GITHUB_OUTPUT"
103113
104114
build-binaries:
105115
needs: version
@@ -183,7 +193,7 @@ jobs:
183193

184194
build-vm-driver:
185195
needs: [pr_metadata, version, build-binaries]
186-
if: needs.pr_metadata.outputs.run_core_e2e == 'true'
196+
if: needs.pr_metadata.outputs.run_core_e2e == 'true' || needs.pr_metadata.outputs.run_integration_upgrades == 'true'
187197
permissions:
188198
contents: read
189199
uses: ./.github/workflows/build-vm-driver.yml
@@ -209,6 +219,49 @@ jobs:
209219
packages: read
210220
uses: ./.github/workflows/prepare-integration-inputs.yml
211221

222+
build-deb-upgrade:
223+
name: Build Debian package for upgrade qualification
224+
needs: [pr_metadata, version, build-binaries, build-vm-driver]
225+
if: needs.pr_metadata.outputs.run_integration_upgrades == 'true'
226+
permissions:
227+
actions: read
228+
contents: read
229+
packages: read
230+
uses: ./.github/workflows/deb-package.yml
231+
with:
232+
deb-version: ${{ needs.version.outputs.deb }}
233+
checkout-ref: ${{ github.sha }}
234+
235+
prepare-integration-upgrades:
236+
name: Prepare upgrade qualification inputs
237+
needs: [pr_metadata, build-binaries, build-images, build-deb-upgrade]
238+
if: needs.pr_metadata.outputs.run_integration_upgrades == 'true'
239+
permissions:
240+
actions: read
241+
contents: read
242+
packages: read
243+
uses: ./.github/workflows/prepare-integration-inputs.yml
244+
with:
245+
deb-artifact-name: deb-linux-amd64
246+
include-deb-upgrade-source: true
247+
248+
integration-upgrades:
249+
name: Integration upgrades
250+
needs: prepare-integration-upgrades
251+
permissions:
252+
actions: read
253+
contents: read
254+
packages: read
255+
uses: ./.github/workflows/integration-runner.yml
256+
with:
257+
category: upgrades
258+
source-sha: ${{ needs.prepare-integration-upgrades.outputs.source_sha }}
259+
integration-inputs-artifact-id: ${{ needs.prepare-integration-upgrades.outputs.integration_inputs_artifact_id }}
260+
test-matrix: >-
261+
[
262+
{"environment":"ubuntu-docker-rootful","installer":"deb-upgrade-source","testsuite":"deb-upgrade"}
263+
]
264+
212265
# Run driver-independent conformance tests.
213266
conformance-integration:
214267
needs: prepare-integration

‎.github/workflows/e2e-label-help.yml‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ permissions: {}
1919
jobs:
2020
hint:
2121
name: Post next-step hint for E2E label
22-
if: github.event.label.name == 'test:e2e' || github.event.label.name == 'test:e2e-gpu' || github.event.label.name == 'test:e2e-kubernetes'
22+
if: github.event.label.name == 'test:e2e' || github.event.label.name == 'test:e2e-gpu' || github.event.label.name == 'test:e2e-kubernetes' || github.event.label.name == 'test:upgrade'
2323
runs-on: ubuntu-latest
2424
permissions:
2525
pull-requests: write
@@ -50,6 +50,11 @@ jobs:
5050
build_summary="supervisor image"
5151
status_summary="The matching required CI gate status on this PR will flip green automatically once the run finishes."
5252
;;
53+
test:upgrade)
54+
suite_summary="the Debian upgrade qualification"
55+
build_summary="the Debian package, VM driver, sandbox image, and supervisor image"
56+
status_summary="This is an optional proof-of-life suite; failures are visible in the workflow run but do not publish a required CI gate status."
57+
;;
5358
test:e2e-kubernetes)
5459
suite_summary="Kubernetes HA and credential-driver E2E"
5560
build_summary="gateway, sandbox, and supervisor images"

‎CI.md‎

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,15 @@ Windows checks are not required for merging and do not run in merge queues.
1818
Main and manual runs also build release binaries, with `continue-on-error: true`
1919
so Windows failures do not fail the workflow.
2020

21-
Three opt-in labels enable the long-running E2E suites:
21+
Four opt-in labels enable the long-running E2E suites:
2222

2323
- `test:e2e` runs the Docker, rootless Podman, Kubernetes, and VM E2E suites
2424
with both managed and standalone compute drivers in `Branch E2E Checks`
2525
- `test:e2e-gpu` runs GPU E2E in `Branch E2E Checks`
26+
- `test:upgrade` runs tmachine Debian upgrade qualification in
27+
`Branch E2E Checks`: the latest retained prerelease is installed first, then
28+
the PR's Debian package is installed and both existing and new sandboxes are
29+
verified
2630
- `test:e2e-kubernetes` runs Kubernetes E2E with the HA Helm overlay
2731
(`replicaCount: 2` and bundled PostgreSQL) and the credential-driver suite
2832
(Kubernetes Secrets plus Vault) in `Branch E2E Checks`
@@ -284,7 +288,7 @@ Flow:
284288

285289
1. Open the PR. copy-pr-bot mirrors it to `pull-request/<N>` automatically.
286290
2. The mirror push runs `Branch Checks` automatically. `Required CI Gates` keeps the PR blocked until the mirror exists, matches the PR head SHA, and the required push-based workflow succeeds. The first `Branch E2E Checks` run only resolves metadata and skips expensive jobs unless an E2E label is already set.
287-
3. A maintainer applies `test:e2e`, `test:e2e-gpu`, and/or `test:e2e-kubernetes`. `E2E Label Help` posts a comment with a link to the existing gated workflow run.
291+
3. A maintainer applies `test:e2e`, `test:e2e-gpu`, `test:upgrade`, and/or `test:e2e-kubernetes`. `E2E Label Help` posts a comment with a link to the existing gated workflow run.
288292
4. The maintainer opens that link and clicks **Re-run all jobs**. This time `pr_metadata` sees the label and the build/E2E jobs run.
289293
5. When the run finishes, the matching `OpenShell / ...` gate status flips to green automatically.
290294
6. New commits push to the mirror automatically and re-trigger `Branch Checks` plus any labeled E2E jobs in `Branch E2E Checks`.
@@ -323,7 +327,7 @@ its own stable result status.
323327
Merge-group runs use the `merge_group` event. The event is distinct from `pull_request` and `push`, and GitHub will not report required checks for queued PRs unless the workflows include it. In this repository:
324328

325329
- `Branch Checks` runs the standard non-E2E gates on the merge-group SHA.
326-
- `Branch E2E Checks` runs core E2E and GPU E2E for merge groups. Kubernetes HA E2E remains optional and label-driven on PRs.
330+
- `Branch E2E Checks` runs core E2E and GPU E2E for merge groups. Debian upgrade qualification and Kubernetes HA E2E remain optional and label-driven on PRs.
327331
- `Helm Lint` runs for merge groups without the PR diff optimization, because the merge-group branch is the final integration state.
328332
- `Trivy Changes` compares the merge-group configuration with its base and rejects new High or Critical findings.
329333
- `Required CI Gates` posts the same `OpenShell / ...` statuses to the merge-group SHA and does not require a `pull-request/<N>` mirror for merge-group events.
@@ -349,7 +353,7 @@ The bot's full administrator documentation is internal to NVIDIA. The only comma
349353
| File | Role |
350354
|---|---|
351355
| `.github/workflows/branch-checks.yml` | Required non-E2E checks. Triggers on `push: pull-request/[0-9]+` for PR mirrors and `merge_group` for queued merges. |
352-
| `.github/workflows/branch-e2e.yml` | Standard, GPU, Kubernetes HA, and Kubernetes credential-driver E2E. PR mirror pushes use `test:e2e`, `test:e2e-gpu`, and `test:e2e-kubernetes` labels; merge groups run core and GPU E2E. |
356+
| `.github/workflows/branch-e2e.yml` | Standard, GPU, Debian upgrade, Kubernetes HA, and Kubernetes credential-driver E2E. PR mirror pushes use `test:e2e`, `test:e2e-gpu`, `test:upgrade`, and `test:e2e-kubernetes` labels; merge groups run core and GPU E2E. |
353357
| `.github/workflows/build-binaries.yml`, `build-vm-driver.yml` | Shared binary matrices used by branch and release workflows. The VM driver remains separate because its build consumes the runtime binaries. |
354358
| `.github/workflows/build-images.yml` | Builds and pushes multi-platform images, then uploads the same OCI images as workflow artifacts. |
355359
| `.github/workflows/package-release-binaries.yml` | Packages raw build artifacts into release tarballs without rebuilding them. |

0 commit comments

Comments
 (0)