Skip to content

ci: migrate to GitHub-hosted runners + attest release builds#2

Merged
m-wells merged 2 commits into
mainfrom
chore/migrate-hosted-runners
Jun 25, 2026
Merged

ci: migrate to GitHub-hosted runners + attest release builds#2
m-wells merged 2 commits into
mainfrom
chore/migrate-hosted-runners

Conversation

@m-wells

@m-wells m-wells commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

What

Migrate CI and Release off the self-hosted runner fleet onto GitHub-hosted
runners, and attach build-provenance attestations to every release archive.

This is the Lattice leg of the homelab self-hosted-runner decommission
(pkgbuilds and Themis already migrated).

Runner migration

Workflow / job Before After
ci.yml check homeserver-pool ubuntu-latest (keeps rust-ci container)
release.yml verify homeserver-pool ubuntu-latest
release.yml build (Linux) homeserver-pool ubuntu-latest (keeps rust-ci container)
release.yml build (Windows) [self-hosted, windows, x64] windows-latest
release.yml build (macOS) [self-hosted, macos, arm64] macos-14 (Apple Silicon)
release.yml publish-crate homeserver-pool ubuntu-latest (keeps rust-ci container)
release.yml release homeserver-pool ubuntu-latest
  • Container parity kept on every Linux job: they still run inside
    ghcr.io/twowells/rust-ci:latest, which carries rustup + the pinned
    toolchain + cc/make/git, so nothing is provisioned on the hosted runner.
  • Windows Package (zip) keeps shell: powershellwindows-latest
    ships Windows PowerShell 5.1 with Compress-Archive built in (verified clean
    swap). Comment reworded to note the 5.1 pin is deliberate.
  • crates.io Trusted Publishing (OIDC) unchanged — works identically on the
    hosted runner.
  • Header/inline comments updated to drop the ARC pool / Windows VM / M2 Max
    provisioning notes that no longer apply.

Build-provenance attestation (release.yml)

  • Added attestations: write to top-level permissions. id-token: write was
    already present (crates.io OIDC) and is reused for provenance signing.
  • New step in the release job, between download-artifact and
    action-gh-release:
    - uses: actions/attest-build-provenance@v4
      with:
        subject-path: |
          dist/lattice-*.tar.gz
          dist/lattice-*.zip
    Pinned to @v4 (current major; latest release v4.1.0, floating v4 tag
    exists). The globs cover the Linux/macOS tar.gz and the Windows zip;
    Lattice ships no .sha256 sidecars, so they match exactly the archives.

Verification coverage

  • CI (ci.yml) triggers on push, so it runs on this branch. Confirmed
    green on a GitHub-hosted runner (see linked run / job log Image:).
  • Release (release.yml) triggers only on v* tags, so it does not
    run on this PR. The windows-latest + macos-14 legs and the new
    attestation step first execute on the next v* tag and are therefore
    unverified until then. No tag is cut here.

Out of scope

  • No pull_request / fork-PR trigger (tracked separately).
  • No Makefile, source, crates.io-publishing, version-verify, or
    artifact-naming changes.

https://claude.ai/code/session_01U5qTPzFxSPun9VccwbLcCy

Move CI and Release off the self-hosted fleet (homeserver-pool ARC pool,
the Windows VM, and the M2 Max macOS runner) onto GitHub-hosted runners,
and attach build-provenance attestations to every release archive.

Runner migration:
- ci.yml `check`: homeserver-pool -> ubuntu-latest (container parity kept:
  still runs inside ghcr.io/twowells/rust-ci:latest).
- release.yml `verify` / `publish-crate` / `release`: homeserver-pool ->
  ubuntu-latest (publish-crate keeps the rust-ci container; crates.io
  Trusted Publishing OIDC is unchanged on hosted).
- release.yml `build` matrix:
    Linux   homeserver-pool        -> ubuntu-latest (keeps rust-ci container)
    Windows [self-hosted,windows]  -> windows-latest
    macOS   [self-hosted,macos]    -> macos-14 (Apple Silicon)
- Windows `Package (zip)` keeps `shell: powershell` — windows-latest ships
  Windows PowerShell 5.1 with Compress-Archive built in.
- Header/inline comments updated to drop the ARC/VM/M2 Max provisioning
  notes now that the runners are hosted.

Build-provenance attestation (release.yml):
- Add `attestations: write` to top-level permissions (id-token: write was
  already present for crates.io OIDC and is reused for provenance signing).
- In the `release` job, sign the archives with
  actions/attest-build-provenance@v4 between download-artifact and
  action-gh-release. Globs cover the Linux/macOS tar.gz and Windows zip;
  Lattice ships no .sha256 sidecars, so they match exactly the archives.

No source, Makefile, crates.io publishing, version-verify, or artifact-
naming changes; no pull_request trigger (tracked separately).

Claude-Session: https://claude.ai/code/session_01U5qTPzFxSPun9VccwbLcCy
@m-wells m-wells force-pushed the chore/migrate-hosted-runners branch from dc85765 to 10c0f65 Compare June 24, 2026 21:32
The four inline.rs and ~8 block.rs anti-quadratic guards assert per-thread
CPU time under a fixed bound. Those bounds (inline 5s, block 10s) were tuned
on the fast self-hosted runner; GitHub-hosted runners are slower per core, so
the dollar-run guard hit 5.8s and tripped the 5s inline bound on hosted CI.

Raise INLINE_SLOW_BOUND 5s->20s and SLOW_BOUND 10s->30s. Genuine quadratic
blowup is orders of magnitude worse (minutes), so the guards still catch it;
the looser bound just survives slower CI hardware without flaking.

Claude-Session: https://claude.ai/code/session_01U5qTPzFxSPun9VccwbLcCy
@m-wells m-wells merged commit fff225d into main Jun 25, 2026
1 check passed
@m-wells m-wells deleted the chore/migrate-hosted-runners branch June 25, 2026 00:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant