Skip to content

Phase 7 COPR + release-sync-manual-channels wrapper + Scoop recipe + install docs#18

Merged
johnpmitsch merged 3 commits into
mainfrom
add/copr-and-install-docs
Jun 11, 2026
Merged

Phase 7 COPR + release-sync-manual-channels wrapper + Scoop recipe + install docs#18
johnpmitsch merged 3 commits into
mainfrom
add/copr-and-install-docs

Conversation

@johnpmitsch

@johnpmitsch johnpmitsch commented Jun 11, 2026

Copy link
Copy Markdown
Collaborator

Summary

Three coordinated changes:

1. Scoop + AUR install paths in README. The Scoop bucket has been seeded for v0.1.4 (since superseded by this PR's Scoop recipe — see #3 below) and qn-bin is now live on AUR. README's install matrix documents both.

2. Phase 7: COPR (Fedora + EPEL) — CI-automated via a thin spec file.

copr-cli build accepts SRPMs or spec files only — it doesn't import prebuilt binary RPMs. To preserve the same-binary-everywhere property (the binary in crates.io, GHCR, .deb, AUR, Homebrew is all one SLSA-attested artifact from cargo-dist's build matrix), this PR adds:

  • packaging/qn-bin.spec — a thin spec whose %prep curls the prebuilt linux-gnu tarball from the GitHub Release and verifies it against the .sha256 sidecar. %install lays the binary into the buildroot. No Rust compilation on COPR's side.
  • .github/workflows/publish-copr.yml — reusable workflow that builds an SRPM from the spec at release time, assembles ~/.config/copr from four COPR_* repo secrets (copr-cli has no env-var fallback), then dispatches via copr-cli build --enable-net=on quicknode/qn <srpm>. COPR's mock rebuilds the SRPM on each Fedora + EPEL chroot in ~30 seconds (no Rust, just curl + install).
  • dist-workspace.toml./publish-copr added to publish-jobs; contents: read granted via github-custom-job-permissions.
  • RELEASING.md — COPR channel documented; one-time COPR project setup notes (chroots, enable-net, the four-secret provisioning).

3. release-sync-manual-channels wrapper + Scoop recipe in this PR. A Justfile recipe that wraps the three manual update commands (Homebrew, Scoop, AUR) into one. Auto-detects the version from the latest tag; defaults the clone root to ~/qn/. Lets a release happen in two commands:

just release-prepare X.Y.Z          # bump → merge → tag → wait for CI
just release-sync-manual-channels   # sync the three local clones, print push commands

Folds in the release-update-scoop-bucket recipe that was sitting in PR #16 (close that as redundant after this lands).

Required setup before the next release exercises COPR

  • COPR project quicknode/qn exists ✓ (created during this PR)
  • Four COPR_* repo secrets set ✓
  • Other channels' secrets unchanged

Until COPR's four secrets are set, custom-publish-copr will fail loudly at the "Configure copr-cli" step with a clear pointer at RELEASING.md. Other publish channels (crates.io, GHCR, .deb) continue to succeed independently.

Test plan

  • dist plan exits 0 (the regenerated release.yml matches what dist generate produces).
  • cargo check passes; Justfile parses (19 recipes); no internal-secret-name leaks per CLAUDE.md.
  • Spec file validated against COPR docs + working multi-arch examples.
  • release-sync-manual-channels exercised locally end-to-end against a throwaway git repo: auto-detects v0.1.4 from latest tag, expands ~/, dispatches each inner recipe correctly, propagates failures.
  • Scoop recipe end-to-end-tested against v0.1.4's actual release: produces a valid JSON manifest with real sha256, correct $version placeholder in the autoupdate block.
  • After merge and COPR's four secrets are in, cut a tag and confirm custom-publish-copr succeeds and dnf copr enable quicknode/qn && dnf install qn works on Fedora 40 + Rocky 9.

Scoop bucket has been seeded for v0.1.4 and the AUR qn-bin package is
registered + installable via yay. Two new install snippets so users on
Windows + Arch don't have to know about the GitHub Releases page.
Homebrew was already in the install matrix.
@johnpmitsch johnpmitsch force-pushed the add/copr-and-install-docs branch from ebb3ec1 to 4f1c7ef Compare June 11, 2026 14:45
@johnpmitsch johnpmitsch changed the title Phase 7 COPR support + README install matrix for Scoop/AUR Wire COPR into release pipeline + README install paths for Scoop/AUR Jun 11, 2026
Adds COPR (Fedora + EPEL) to the cargo-dist user_publish_jobs pipeline.
Same shape as the existing crates.io / Docker / .deb publish jobs.

Why the spec-file approach:

  copr-cli's only build entrypoint accepts SRPMs or spec files — it
  doesn't import prebuilt binary RPMs. So the binary-everywhere
  property we have for crates.io, GHCR, .deb, and AUR needed a thin
  spec whose %prep downloads the SLSA-attested upstream tarball
  cargo-dist already published, verifies it against the .sha256
  sidecar, and then %install just lays the binary into the buildroot.
  COPR's mock chroot does this on each Fedora + EPEL chroot in
  ~30 seconds — no Rust toolchain involved, single trust chain.

Why four secrets instead of one combined config blob:

  copr-cli only reads credentials from ~/.config/copr (no env-var
  fallback per copr/v3/helpers.py's config_from_file). The workflow
  has to assemble that file at runtime regardless. Splitting the four
  fields (login, username, token, copr_url) into separate repo secrets
  makes each one safe to paste as a single line (no multiline blob to
  get malformed) and lets the token be rotated without touching the
  other three.

Changes:

  * packaging/qn-bin.spec — the thin spec. ExclusiveArch: x86_64
    aarch64. Per-arch Source URL via ifarch, sha256 verification in
    %prep before %setup.

  * .github/workflows/publish-copr.yml — reusable workflow invoked
    by cargo-dist. Builds the SRPM from the spec (with QN_VERSION
    passed in from the dist manifest), assembles ~/.config/copr from
    the four COPR_* secrets, then dispatches via
    `copr-cli build --enable-net=on quicknode/qn <srpm>`.

    --enable-net=on is required because %prep curls the tarball;
    COPR's default mock has network disabled.

  * dist-workspace.toml — adds ./publish-copr to publish-jobs and
    grants `contents: read` via github-custom-job-permissions.

  * RELEASING.md — documents the COPR channel under CI publish
    channels and the four-secret provisioning flow.

  * release.yml — regenerated to include custom-publish-copr.

The job is gated by cargo-dist on `!is_prerelease`, same as the
others. Until all four COPR_* secrets are set on the repo, the job
will fail loudly at the "Configure copr-cli" step with a clear error
listing which fields are missing — the rest of the release continues
to succeed.

Earlier in this branch I went down a wrong path: a `release-build-copr-rpms`
Justfile recipe + [package.metadata.generate-rpm] block that produced
binary RPMs locally with cargo-generate-rpm. `copr-cli build` doesn't
accept binary RPMs, so that path was a dead-end. Reset and rewrote
before opening the PR for review.
@johnpmitsch johnpmitsch force-pushed the add/copr-and-install-docs branch from 4f1c7ef to ef100f4 Compare June 11, 2026 15:20
machito
machito previously approved these changes Jun 11, 2026
`release-prepare` ships the automated half of a release end-to-end:
bump, PR, merge, tag, CI runs all the in-CI publish jobs. The other
half (Homebrew, Scoop, AUR — currently maintainer-driven because we
don't yet have the credentials to automate the pushes) was three
separate `just release-update-*` invocations with three local clone
paths to remember and three push commands to type. Easy to forget,
easy to skip a channel.

This commit collapses that to one wrapper:

  just release-sync-manual-channels

Auto-detects the just-released version from the latest git tag,
expects three sibling clones under ~/qn/ (the established convention
across this repo's recipes), runs the three release-update-* recipes
in sequence, then prints the three `git -C ... push` commands the
maintainer reviews and runs to publish.

Both arguments are optional and overridable:

  just release-sync-manual-channels ~/work/quicknode      # alt root
  just release-sync-manual-channels ~/qn 0.1.4            # backfill

Also folds in the `release-update-scoop-bucket` recipe (previously in
PR #16, which is now redundant — close it after this lands). Scrubbed
the invented secret-name reference from its comment per CLAUDE.md.

Adds a "Quick release" section at the top of RELEASING.md showing the
happy-path two-command flow:

  just release-prepare X.Y.Z
  # … wait for CI …
  just release-sync-manual-channels

The detailed per-channel sections stay below it as reference for when
something fails or the maintainer needs to drive a single channel
manually.
@johnpmitsch johnpmitsch changed the title Wire COPR into release pipeline + README install paths for Scoop/AUR Phase 7 COPR + release-sync-manual-channels wrapper + Scoop recipe + install docs Jun 11, 2026
@johnpmitsch johnpmitsch merged commit 2723542 into main Jun 11, 2026
13 checks passed
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.

2 participants