Skip to content

Foundation pipelines · T01–T25 ​

Encyclopedia home · Search machine-readable catalog

Each code block is a complete workflow file for the stated platform. App code, provisioned resources, and tools listed as prerequisites are supplied by the consuming repository or lab. Privileged templates are manual and use trusted, dedicated runners and reviewed target environments.

T01 ​

First Gitea CI workflow

  • Platform Gitea Actions.
  • File .gitea/workflows/t01-first-gitea-ci-workflow.yml.
  • Prerequisites README.md tracked.
  • Execution verify.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: First Gitea CI workflow
on:
- push
- pull_request
jobs:
  verify:
    runs-on: ubuntu-latest
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: https://github.com/actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Verify checkout
      run: |-
        git rev-parse --verify HEAD
    - name: Execute
      run: |-
        test -s README.md
    - name: Verify result
      run: |-
        uname -m
        printf 'verified=%s\n' "$(git rev-parse HEAD)"

Verification and failure handling. A runner probes the checked-out commit and fails if the fixture file is removed.

Related CICD-001 · CICD-013 · Workflow reference

T02 ​

GitHub PR verification with an aggregate gate

  • Platform GitHub Actions.
  • File .github/workflows/t02-github-pr-verification-with-an-aggregate-gate.yml.
  • Prerequisites README.md and a two-commit test repository.
  • Execution verify → gate.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: GitHub PR verification with an aggregate gate
on:
- push
- pull_request
jobs:
  verify:
    runs-on: ubuntu-latest
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        test -s README.md
    - name: Execute
      run: |-
        git diff --check HEAD^ HEAD
    - name: Verify result
      run: |-
        test -s README.md
  gate:
    needs: verify
    if: ${{ !cancelled() }}
    runs-on: ubuntu-latest
    timeout-minutes: 5
    steps:
    - name: Enforce verification result
      env:
        RESULT: ${{ needs.verify.result }}
      run: test "$RESULT" = success
permissions:
  contents: read

Verification and failure handling. Require the named gate in branch protection. A deliberately missing README makes the gate fail even when verify is skipped.

Related CICD-018 · CICD-491 · Workflow reference

T03 ​

Python CI with uv

  • Platform GitHub Actions.
  • File .github/workflows/t03-python-ci-with-uv.yml.
  • Prerequisites pyproject.toml, uv.lock and pytest/Ruff in the default dev dependency group.
  • Execution verify.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: Python CI with uv
on:
- push
- pull_request
jobs:
  verify:
    runs-on: ubuntu-latest
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - uses: astral-sh/setup-uv@v6
      with:
        version: 0.8.22
    - name: Preflight
      run: |-
        test -s uv.lock
    - name: Execute
      run: |-
        uv sync --locked
        uv run --locked ruff check .
    - name: Verify result
      run: |-
        uv run --locked pytest -q --junitxml=junit.xml
permissions:
  contents: read

Verification and failure handling. The workflow provisions pinned uv. Stale lock state, a lint problem, or a failing test prevents a green check.

Related CICD-066 · CICD-067 · Workflow reference

T04 ​

Node test and build

  • Platform GitHub Actions.
  • File .github/workflows/t04-node-test-and-build.yml.
  • Prerequisites package.json, package-lock.json, test and build scripts, Node 22.
  • Execution verify.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: Node test and build
on:
- push
- pull_request
jobs:
  verify:
    runs-on: ubuntu-latest
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        test -s package-lock.json
    - name: Execute
      run: |-
        npm ci
        npm test -- --ci
    - name: Verify result
      run: |-
        npm run build
        test -d dist
permissions:
  contents: read

Verification and failure handling. Use the project layout and inspect dist only after tests pass.

Related CICD-069 · CICD-070 · Workflow reference

T05 ​

Go verified release build

  • Platform GitHub Actions.
  • File .github/workflows/t05-go-verified-release-build.yml.
  • Prerequisites go.mod, cmd/app and approved Go toolchain.
  • Execution verify.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: Go verified release build
on:
- push
- pull_request
jobs:
  verify:
    runs-on: ubuntu-latest
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        test -s go.mod
    - name: Execute
      run: |-
        go mod verify
        go test -race ./...
    - name: Verify result
      run: |-
        mkdir -p dist
        CGO_ENABLED=0 go build -trimpath -o dist/app ./cmd/app
        test -x dist/app
permissions:
  contents: read

Verification and failure handling. Verify modules and run race detection before building the Linux candidate.

Related CICD-072 · CICD-073 · Workflow reference

T06 ​

Java Maven verification

  • Platform GitHub Actions.
  • File .github/workflows/t06-java-maven-verification.yml.
  • Prerequisites mvnw with executable mode, pom.xml and approved JDK.
  • Execution verify.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: Java Maven verification
on:
- push
- pull_request
jobs:
  verify:
    runs-on: ubuntu-latest
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        test -x mvnw
    - name: Execute
      run: |-
        ./mvnw --batch-mode --no-transfer-progress verify
    - name: Verify result
      run: |-
        find target -name '*.jar' -size +0 -print | grep .
permissions:
  contents: read

Verification and failure handling. Maven verify includes project-configured integration tests. Check candidate count and filename.

Related CICD-076 · Workflow reference

T07 ​

Rust locked build

  • Platform GitHub Actions.
  • File .github/workflows/t07-rust-locked-build.yml.
  • Prerequisites Cargo.lock, rustfmt and approved Rust toolchain.
  • Execution verify.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: Rust locked build
on:
- push
- pull_request
jobs:
  verify:
    runs-on: ubuntu-latest
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        test -s Cargo.lock
    - name: Execute
      run: |-
        cargo fmt --all -- --check
        cargo test --locked --all-targets
    - name: Verify result
      run: |-
        cargo build --release --locked
permissions:
  contents: read

Verification and failure handling. Validate dependency and compiler versions independently.

Related CICD-074 · CICD-075 · Workflow reference

T08 ​

.NET locked build and tests

  • Platform GitHub Actions.
  • File .github/workflows/t08-net-locked-build-and-tests.yml.
  • Prerequisites global.json plus a committed NuGet lock and installed SDK.
  • Execution verify.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: .NET locked build and tests
on:
- push
- pull_request
jobs:
  verify:
    runs-on: ubuntu-latest
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        test -s global.json
    - name: Execute
      run: |-
        dotnet restore --locked-mode
        dotnet build --no-restore
    - name: Verify result
      run: |-
        dotnet test --no-build --logger trx
permissions:
  contents: read

Verification and failure handling. Read .trx files for failures and pin the exact SDK in runner setup.

Related CICD-078 · Workflow reference

T09 ​

CMake native build and tests

  • Platform GitHub Actions.
  • File .github/workflows/t09-cmake-native-build-and-tests.yml.
  • Prerequisites CMakeLists.txt enables testing and compiler is installed.
  • Execution verify.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: CMake native build and tests
on:
- push
- pull_request
jobs:
  verify:
    runs-on: ubuntu-latest
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        test -s CMakeLists.txt
    - name: Execute
      run: |-
        cmake -S . -B build -DCMAKE_BUILD_TYPE=Release
        cmake --build build --parallel 2
    - name: Verify result
      run: |-
        ctest --test-dir build --output-on-failure --no-tests=error
permissions:
  contents: read

Verification and failure handling. Removing tests fails the final stage instead of silently passing.

Related CICD-079 · Workflow reference

T10 ​

TypeScript monorepo compilation

  • Platform GitHub Actions.
  • File .github/workflows/t10-typescript-monorepo-compilation.yml.
  • Prerequisites pinned pnpm and Corepack on runner, pnpm-lock.yaml, workspace scripts.
  • Execution verify.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: TypeScript monorepo compilation
on:
- push
- pull_request
jobs:
  verify:
    runs-on: ubuntu-latest
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        test -s pnpm-lock.yaml
    - name: Execute
      run: |-
        corepack pnpm install --frozen-lockfile
        corepack pnpm -r run lint
    - name: Verify result
      run: |-
        corepack pnpm -r --workspace-concurrency=3 run build
permissions:
  contents: read

Verification and failure handling. Build workspace packages only after lint and lock verification.

Related CICD-388 · CICD-393 · Workflow reference

T11 ​

Python package and artifact handoff

  • Platform GitHub Actions.
  • File .github/workflows/t11-python-package-and-artifact-handoff.yml.
  • Prerequisites Python package metadata, pinned uv available and importable test package.
  • Execution build → install.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: Python package and artifact handoff
on:
  workflow_dispatch: {}
jobs:
  build:
    runs-on: &id001
    - self-hosted
    - linux
    - platform-lab
    timeout-minutes: 20
    defaults: &id002
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Check package manifest
      run: |-
        test -s pyproject.toml
    - name: Build and hash wheel
      run: |-
        uv build --wheel --out-dir dist
        sha256sum dist/*.whl > wheel.sha256
    - uses: actions/upload-artifact@v4
      with:
        name: verified-wheel
        path: |-
          dist/*.whl
          wheel.sha256
        retention-days: 7
        if-no-files-found: error
  install:
    runs-on: *id001
    timeout-minutes: 20
    defaults: *id002
    needs: build
    steps:
    - uses: actions/download-artifact@v4
      with:
        name: verified-wheel
        path: .
    - name: Verify and install artifact
      run: |-
        sha256sum --strict --check wheel.sha256
        python -m venv "$RUNNER_TEMP/wheel"
        "$RUNNER_TEMP/wheel/bin/pip" install dist/*.whl
        cd "$RUNNER_TEMP"
        "$RUNNER_TEMP/wheel/bin/python" -c 'import app'
permissions:
  contents: read

Verification and failure handling. Verifies a fresh install. Enable artifact collection for dist and wheel.sha256.

Related CICD-090 · CICD-093 · CICD-094 · Workflow reference

T12 ​

JUnit and coverage gate

  • Platform GitHub Actions.
  • File .github/workflows/t12-junit-and-coverage-gate.yml.
  • Prerequisites Python repo with pinned uv, pytest and pytest-cov.
  • Execution delivery.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: JUnit and coverage gate
on:
  workflow_dispatch: {}
jobs:
  delivery:
    runs-on:
    - self-hosted
    - linux
    - platform-lab
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        test -s uv.lock
    - name: Execute
      run: |-
        uv sync --locked
    - name: Verify result
      run: |-
        mkdir -p reports
        uv run --locked pytest --cov=app --cov-fail-under=80 --junitxml=reports/junit.xml
    - uses: actions/upload-artifact@v4
      with:
        name: t12-evidence
        path: reports/junit.xml
        retention-days: 7
        if-no-files-found: warn
      if: ${{ !cancelled() }}
permissions:
  contents: read

Verification and failure handling. Read test failure and coverage thresholds independently. Collect reports even on a failed gate.

Related CICD-062 · CICD-063 · Workflow reference

T13 ​

Compose PostgreSQL integration

  • Platform GitHub Actions.
  • File .github/workflows/t13-compose-postgresql-integration.yml.
  • Prerequisites compose.yaml has db healthcheck; Python tests and pinned uv available.
  • Execution verify.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: Compose PostgreSQL integration
on:
- push
- pull_request
jobs:
  verify:
    runs-on: ubuntu-latest
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - uses: astral-sh/setup-uv@v6
      with:
        version: 0.8.22
    - name: Preflight
      run: |-
        docker compose config --quiet
    - name: Execute
      run: |-
        export COMPOSE_PROJECT_NAME="ci-${GITHUB_RUN_ID:?}-${GITHUB_RUN_ATTEMPT:?}"
        trap 'docker compose down --remove-orphans -v' EXIT
        docker compose up -d --wait db
        uv sync --locked
        uv run --locked pytest -q tests/integration
    - name: Verify result
      run: |-
        echo 'database integration passed'
permissions:
  contents: read

Verification and failure handling. Run with an isolated per-run database. Configure test DSN with the port exposed by the fixture.

Related CICD-068 · CICD-340 · Workflow reference

T14 ​

Frontend browser testing

  • Platform GitHub Actions.
  • File .github/workflows/t14-frontend-browser-testing.yml.
  • Prerequisites package lock and Playwright Chromium project with local webServer config.
  • Execution verify.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: Frontend browser testing
on:
- push
- pull_request
jobs:
  verify:
    runs-on: ubuntu-latest
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        test -s package-lock.json
    - name: Execute
      run: |-
        npm ci
        npx --no-install playwright install --with-deps chromium
    - name: Verify result
      run: |-
        npx --no-install playwright test --project=chromium
permissions:
  contents: read

Verification and failure handling. Test trace collection on a failed assertion.

Related CICD-083 · Workflow reference

T15 ​

Container build and local smoke test

  • Platform GitHub Actions.
  • File .github/workflows/t15-container-build-and-local-smoke-test.yml.
  • Prerequisites Dockerfile serves /healthz on port 8000.
  • Execution verify.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: Container build and local smoke test
on:
- push
- pull_request
jobs:
  verify:
    runs-on: ubuntu-latest
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        test -s Dockerfile
    - name: Execute
      run: |-
        docker build -t "web:$GITHUB_SHA" .
    - name: Verify result
      run: |-
        id=$(docker run -d -p 127.0.0.1:18000:8000 "web:$GITHUB_SHA")
        trap 'docker rm -f "$id" >/dev/null' EXIT
        curl -fsS --retry 10 --retry-connrefused --retry-delay 1 http://127.0.0.1:18000/healthz | jq -e '.status=="ok"'
permissions:
  contents: read

Verification and failure handling. Verify the actual built image. Use a runner with isolated ports.

Related CICD-112 · CICD-282 · Workflow reference

Use CF-001 · CF-076 · CF-100 to assemble the dependency-free HTTP fixture and its test. The fixture source bind is for the disposable example.

T16 ​

Multi-architecture image validation

  • Platform GitHub Actions.
  • File .github/workflows/t16-multi-architecture-image-validation.yml.
  • Prerequisites native amd64 and arm64 workers or approved QEMU Buildx support.
  • Execution delivery.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: Multi-architecture image validation
on:
  workflow_dispatch: {}
jobs:
  delivery:
    runs-on:
    - self-hosted
    - linux
    - platform-lab
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        docker buildx inspect --bootstrap
    - name: Execute
      run: |-
        docker buildx build --platform linux/amd64,linux/arm64 --output type=oci,dest=web.oci.tar .
    - name: Verify result
      run: |-
        tar -tf web.oci.tar | grep -Ex 'index.json'
permissions:
  contents: read

Verification and failure handling. Export both targets and test the artifact on both target architectures before release.

Related CICD-109 · CICD-126 · Workflow reference

T17 ​

GHCR immutable candidate publish

  • Platform GitHub Actions.
  • File .github/workflows/t17-ghcr-immutable-candidate-publish.yml.
  • Prerequisites Dockerfile, approved registry access and configured staging environment.
  • Execution delivery.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: GHCR immutable candidate publish
on:
  workflow_dispatch: {}
jobs:
  delivery:
    runs-on: ubuntu-latest
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    permissions:
      contents: read
      packages: write
    if: github.ref == 'refs/heads/main'
    environment: release
    env:
      GHCR_TOKEN: ${{ github.token }}
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        test -s Dockerfile
    - name: Execute
      run: |-
        image="ghcr.io/${GITHUB_REPOSITORY,,}:$GITHUB_SHA"
        docker build -t "$image" .
        docker run --rm --entrypoint python "$image" -m compileall -q /app
        printf '%s' "${GHCR_TOKEN:?}" | docker login ghcr.io -u "$GITHUB_ACTOR" --password-stdin
        docker push "$image"
        docker logout ghcr.io
    - name: Verify result
      run: |-
        docker buildx imagetools inspect "ghcr.io/${GITHUB_REPOSITORY,,}:$GITHUB_SHA"
permissions:
  contents: read
concurrency:
  group: t17-reviewed-delivery
  cancel-in-progress: false

Verification and failure handling. Registry metadata must identify the pushed candidate. Use package visibility appropriate for the repository.

Related CICD-123 · CICD-124 · Workflow reference

T18 ​

Gitea registry candidate publish

  • Platform Gitea Actions.
  • File .gitea/workflows/t18-gitea-registry-candidate-publish.yml.
  • Prerequisites approved registry, scoped Gitea access token, buildable Dockerfile, provisioned trusted runner.
  • Execution delivery.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: Gitea registry candidate publish
on:
  workflow_dispatch: {}
jobs:
  delivery:
    runs-on: trusted-publish
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    if: github.ref == 'refs/heads/main'
    env:
      GITEA_PACKAGE_USER: ${{ vars.GITEA_PACKAGE_USER }}
      GITEA_REGISTRY: ${{ vars.GITEA_REGISTRY }}
      GITEA_PACKAGE_TOKEN: ${{ secrets.GITEA_PACKAGE_TOKEN }}
    steps:
    - uses: https://github.com/actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        test -s Dockerfile
    - name: Execute
      run: |-
        image="${GITEA_REGISTRY:?}/${GITHUB_REPOSITORY,,}:$GITHUB_SHA"
        docker build -t "$image" .
        printf '%s' "${GITEA_PACKAGE_TOKEN:?}" | docker login "$GITEA_REGISTRY" -u "${GITEA_PACKAGE_USER:?}" --password-stdin
        trap 'docker logout "$GITEA_REGISTRY"' EXIT
        docker push "$image"
        docker buildx imagetools inspect "$image"
    - name: Verify result
      run: |-
        echo 'registry publish verified'

Verification and failure handling. Only run trusted main refs on a dedicated lab runner. Configure compatible CLI and protected secrets.

Related CICD-202 · CICD-205 · Workflow reference

T19 ​

Release archive verification

  • Platform GitHub Actions.
  • File .github/workflows/t19-release-archive-verification.yml.
  • Prerequisites dist/app.tar.gz is committed only as a synthetic fixture or produced by a prior build in the same job.
  • Execution delivery.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: Release archive verification
on:
  workflow_dispatch: {}
jobs:
  delivery:
    runs-on: ubuntu-latest
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        test -s dist/app.tar.gz
    - name: Execute
      run: |-
        tar -tzf dist/app.tar.gz
        sha256sum dist/app.tar.gz > SHA256SUMS
    - name: Verify result
      run: |-
        sha256sum --strict --check SHA256SUMS
permissions:
  contents: read

Verification and failure handling. A changed archive byte fails verification. Establish artifact provenance for real releases.

Related CICD-093 · CICD-131 · Workflow reference

T20 ​

Helm render and test staging

  • Platform GitHub Actions.
  • File .github/workflows/t20-helm-render-and-test-staging.yml.
  • Prerequisites lab namespace staging, chart helm/web and configured kubecontext.
  • Execution delivery.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: Helm render and test staging
on:
  workflow_dispatch: {}
jobs:
  delivery:
    runs-on:
    - self-hosted
    - linux
    - platform-lab
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    if: github.ref == 'refs/heads/main'
    environment: staging
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        helm lint ./helm/web
    - name: Execute
      run: |-
        helm template web ./helm/web -n staging > rendered.yaml
        kubectl -n staging apply --dry-run=server -f rendered.yaml
        helm upgrade --install web ./helm/web -n staging --atomic --timeout 4m
    - name: Verify result
      run: |-
        helm test web -n staging --logs --timeout 3m
permissions:
  contents: read
concurrency:
  group: t20-reviewed-delivery
  cancel-in-progress: false

Verification and failure handling. Add a Helm test hook and verify intended staging context.

Related CICD-141 · CICD-148 · CICD-149 · Workflow reference

T21 ​

Kubernetes digest staging rollout

  • Platform GitHub Actions.
  • File .github/workflows/t21-kubernetes-digest-staging-rollout.yml.
  • Prerequisites staging Deployment web, container web and scoped kubecontext.
  • Execution delivery.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: Kubernetes digest staging rollout
on:
  workflow_dispatch: {}
jobs:
  delivery:
    runs-on:
    - self-hosted
    - linux
    - platform-lab
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    if: github.ref == 'refs/heads/main'
    environment: staging
    env:
      HEALTH_URL: ${{ vars.HEALTH_URL }}
      IMAGE: ${{ vars.IMAGE }}
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        kubectl auth can-i patch deploy -n staging | grep -Fx yes
    - name: Execute
      run: |-
        [[ "${IMAGE:?}" =~ @sha256:[0-9a-f]{64}$ ]]
        kubectl -n staging set image deployment/web web="$IMAGE"
        kubectl -n staging rollout status deployment/web --timeout=180s
    - name: Verify result
      run: |-
        curl -fsS --max-time 10 "${HEALTH_URL:?}" | jq -e '.status=="ok"'
permissions:
  contents: read
concurrency:
  group: t21-reviewed-delivery
  cancel-in-progress: false

Verification and failure handling. Verify API convergence and independent traffic health.

Related CICD-134 · CICD-135 · Workflow reference

T22 ​

Reviewed lab rollback

  • Platform GitHub Actions.
  • File .github/workflows/t22-reviewed-lab-rollback.yml.
  • Prerequisites immutable known-good image and reviewed compatibility assessment.
  • Execution delivery.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: Reviewed lab rollback
on:
  workflow_dispatch: {}
jobs:
  delivery:
    runs-on:
    - self-hosted
    - linux
    - platform-lab
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    if: github.ref == 'refs/heads/main'
    environment: staging
    env:
      HEALTH_URL: ${{ vars.HEALTH_URL }}
      KNOWN_GOOD_IMAGE: ${{ vars.KNOWN_GOOD_IMAGE }}
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        kubectl -n staging rollout history deployment/web
    - name: Execute
      run: |-
        [[ "${KNOWN_GOOD_IMAGE:?}" =~ @sha256:[0-9a-f]{64}$ ]]
        kubectl -n staging set image deployment/web web="$KNOWN_GOOD_IMAGE"
        kubectl -n staging rollout status deploy/web --timeout=180s
    - name: Verify result
      run: |-
        curl -fsS --max-time 10 "${HEALTH_URL:?}"
permissions:
  contents: read
concurrency:
  group: t22-reviewed-delivery
  cancel-in-progress: false

Verification and failure handling. Use a known-good digest and do not overwrite GitOps desired state imperatively.

Related CICD-167 · CICD-304 · Workflow reference

T23 ​

GitOps pull request validation

  • Platform GitHub Actions.
  • File .github/workflows/t23-gitops-pull-request-validation.yml.
  • Prerequisites overlays in environments/staging and kubectl client.
  • Execution verify.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: GitOps pull request validation
on:
- push
- pull_request
jobs:
  verify:
    runs-on: ubuntu-latest
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        test -s environments/staging/kustomization.yaml
    - name: Execute
      run: |-
        kubectl kustomize environments/staging > rendered.yaml
        grep -F 'image:' rendered.yaml
    - name: Verify result
      run: |-
        grep -Eq 'image: .*@sha256:[0-9a-f]{64}' rendered.yaml
permissions:
  contents: read

Verification and failure handling. Prove the artifact remains immutable. Add schema/policy validation before applying.

Related CICD-168 · CICD-293 · Workflow reference

T24 ​

Dependency and image scanning

  • Platform GitHub Actions.
  • File .github/workflows/t24-dependency-and-image-scanning.yml.
  • Prerequisites preprovisioned scanner and Docker builder, trusted CI runner.
  • Execution delivery.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: Dependency and image scanning
on:
  workflow_dispatch: {}
jobs:
  delivery:
    runs-on:
    - self-hosted
    - linux
    - platform-lab
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        trivy version
    - name: Execute
      run: |-
        docker build -t "candidate:$GITHUB_SHA" .
        trivy fs --exit-code 1 --scanners vuln --severity HIGH,CRITICAL .
    - name: Verify result
      run: |-
        trivy image --exit-code 1 --severity HIGH,CRITICAL "candidate:$GITHUB_SHA"
permissions:
  contents: read

Verification and failure handling. Remove trust in mutable tags by storing the tested digest. Use reviewed expires-on exceptions.

Related CICD-176 · CICD-492 · Workflow reference

T25 ​

Pipeline diagnostics and evidence

  • Platform GitHub Actions.
  • File .github/workflows/t25-pipeline-diagnostics-and-evidence.yml.
  • Prerequisites disposable fixture and approved sanitized evidence retention.
  • Execution delivery.
  • Validation syntax-validated. External tools and provider controls require validation in your lab.
yaml
name: Pipeline diagnostics and evidence
on:
  workflow_dispatch: {}
jobs:
  delivery:
    runs-on: ubuntu-latest
    timeout-minutes: 20
    defaults:
      run:
        shell: bash
    steps:
    - uses: actions/checkout@v4
      with:
        persist-credentials: false
        fetch-depth: 0
    - name: Preflight
      run: |-
        git diff --check
    - name: Execute
      run: |-
        mkdir -p reports
        git rev-parse HEAD > reports/commit.txt
        uname -sm > reports/runner.txt
    - name: Verify result
      run: |-
        test -s reports/commit.txt
        test -s reports/runner.txt
    - uses: actions/upload-artifact@v4
      with:
        name: t25-evidence
        path: reports/
        retention-days: 7
        if-no-files-found: error
permissions:
  contents: read

Verification and failure handling. A short-lived artifact preserves basic runner evidence without collecting credentials.

Related CICD-180 · CICD-198 · Workflow reference