ci: replace manual release workflow with cargo-dist#128
Merged
Conversation
The manual release.yml pinned actions/upload-artifact and download-artifact at v3, which GitHub now hard-fails. Rather than just bumping the actions, adopt cargo-dist (v0.31.0) following the setup already used in dfinity/ic-wasm. - Add dist-workspace.toml mirroring ic-wasm: github CI backend, shell installer, install-updater, and SHA-pinned GitHub Actions. - Build for x86_64/aarch64 Linux (glibc) and x86_64/aarch64 macOS, all on native runners (system OpenSSL, no cross-compile). Replaces the old linux64/macos/arm32 set; the 32-bit arm target is dropped. - Add repository field and [profile.dist] to Cargo.toml. - release.yml is now generated by `dist generate` (verified byte-for- byte with `dist generate --check`). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
adamspofford-dfinity
approved these changes
Jun 16, 2026
There was a problem hiding this comment.
Pull request overview
This PR replaces the repo’s hand-rolled GitHub Actions release workflow with a cargo-dist–generated workflow to fix failures caused by deprecated Action versions and runner retirement, and to standardize release artifact generation.
Changes:
- Add
dist-workspace.tomlto configure cargo-dist (including pinning GitHub Actionsuses:to commit SHAs). - Update
Cargo.tomlwith therepositoryfield required by cargo-dist and add a[profile.dist]. - Regenerate
.github/workflows/release.ymlviadist generate, replacing the prior manual build/test/publish jobs.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| dist-workspace.toml | Introduces cargo-dist workspace configuration and pins GitHub Actions to commit SHAs. |
| Cargo.toml | Adds repository metadata and a dist-specific release profile. |
| .github/workflows/release.yml | Replaces the manual release workflow with the cargo-dist–generated plan/build/host pipeline. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
The
Releaseworkflow fails on every run: it pinnedactions/upload-artifactandactions/download-artifactat v3, which GitHub now automatically hard-fails. The workflow also targeted the retiredubuntu-20.04runner.Rather than patch the hand-rolled workflow, this adopts cargo-dist (v0.31.0), following the setup already in use in dfinity/ic-wasm.
What
dist-workspace.toml(new) — mirrors ic-wasm:ci = "github", shell installer,install-updater = true, and a[dist.github-action-commits]block that pins all generateduses:lines to full commit SHAs (matches our security policy).Cargo.toml— adds therepositoryfield (required by dist) and[profile.dist]..github/workflows/release.yml— regenerated bydist generate; replaces the manual plan/build/test/publish jobs.Target platforms
Built on native runners (so system OpenSSL is available — no cross-compile/vendoring):
x86_64-unknown-linux-gnuaarch64-unknown-linux-gnux86_64-apple-darwinaarch64-apple-darwinBehavioral changes
.tar.xzarchives named by target triple, plus an install script + checksums (not the old bareic-repl-linux64/ic-repl-macos/ic-repl-arm32binaries).arm-unknown-linux-gnueabihfbuild is dropped, replaced by 64-bitaarch64. The[target.arm-unknown-linux-gnueabihf] opensslblock inCargo.tomlis left in place (inert in CI, preserves local arm32 cross-builds).**[0-9]+.[0-9]+.[0-9]+*); the existing0.7.8-style convention still matches. Runs a no-publishdist planon PRs.Verification
dist generate --checkpasses (exit 0) — the committedrelease.ymlis byte-identical to dist 0.31.0's output, so it won't drift.dist planresolves the matrix above; all targets are native builds.🤖 Generated with Claude Code