Skip to content

Make CI runnable on the QuickNode fork (re-opened, targets main-qn)#4

Merged
McSim85 merged 3 commits into
main-qnfrom
qn/ci-make-runnable-on-fork
May 12, 2026
Merged

Make CI runnable on the QuickNode fork (re-opened, targets main-qn)#4
McSim85 merged 3 commits into
main-qnfrom
qn/ci-make-runnable-on-fork

Conversation

@McSim85
Copy link
Copy Markdown

@McSim85 McSim85 commented May 12, 2026

Re-opens PR #2, which was auto-closed by GitHub when the branch was renamed from `ci-make-runnable-on-fork` to `qn/ci-make-runnable-on-fork` via the rename API. Branch reference on the original PR didn't follow the rename, so GitHub closed it. The branch still has all the commits — this is just a fresh PR pointing it at the new default base (`main-qn`).

Problem

Three independent issues prevented `.github/workflows/{test,build,release}.yml` from running on `quiknode-labs/shredstream-proxy`:

  1. Self-hosted runner reference. All three workflows use `runs-on: ubuntu-22.04-16c-64g-public` — Jito's private runner pool. The fork has no access, so every job would queue indefinitely.

  2. Missing Rust toolchain installation. The `setup-rust` composite action only installed protoc; it assumed `rustc` was already present on the runner (true on Jito's self-hosted image, not on stock GitHub-hosted `ubuntu-22.04`).

  3. Hardcoded Docker Hub publish. Both `build.yml` and `release.yml` pushed to `jitolabs/jito-shredstream-proxy:*` using `secrets.DOCKERHUB_USER` / `secrets.DOCKERHUB_PWD`. Those secrets don't exist on the fork and shouldn't — they're Jito's. Our deploy pipeline pulls binaries from an OCI bucket via `role_chain_build`, not Docker Hub.

Changes

`.github/actions/setup-rust/action.yaml`

  • Replaced the implicit "runner already has rust" assumption with `actions-rust-lang/setup-rust-toolchain@v1`, which reads `rust-toolchain.toml` as the single source of truth (picking up both `channel = "1.84"` and the full components list).

`.github/workflows/test.yml`

  • Switched runner to `ubuntu-22.04`. No other changes.

`.github/workflows/build.yml`

  • Switched runner to `ubuntu-22.04`.
  • Dropped the Docker Buildx setup, Docker Hub login, and `docker/build-push-action` step.
  • Added `cargo build --release --locked --bin jito-shredstream-proxy` to verify a full release build still succeeds.

`.github/workflows/release.yml`

  • Switched runner to `ubuntu-22.04`.
  • Replaced Docker-based binary extraction (build image → push → `docker run --entrypoint cat …`) with a direct `cargo build --release`.
  • The resulting binary is staged as `jito-shredstream-proxy-x86_64-unknown-linux-gnu` (same artifact name as before) and uploaded to the GitHub Release by `softprops/action-gh-release@v2` on tag push.
  • Dropped multi-arch (arm64) build since the fleet is x86_64-only (znver3/4/5 per `role_chain_build`).

Diff summary

25 lines added, 57 removed.

Note on Cursor feedback from the original PR

Cursor flagged that the previous attempt (`dtolnay/rust-toolchain@1.84` with explicit components) duplicated the source of truth held by `rust-toolchain.toml`. That feedback is addressed in the second commit on this branch — `actions-rust-lang/setup-rust-toolchain@v1` reads the toml directly, no duplication.

Test plan

Local YAML syntax check passed (`pyyaml.safe_load` on all four files). The workflows can't actually be executed until Actions is enabled on the fork — once enabled, this PR's check runs will start working.

🤖 Generated with Claude Code


Note

Medium Risk
Medium risk because it changes the release/build pipeline (removes Docker build/push and alters artifact staging), which could impact produced artifacts and release automation despite being CI-only code.

Overview
Makes CI runnable on stock GitHub-hosted runners by switching test, build, and release jobs to runs-on: ubuntu-22.04 and updating the setup-rust composite action to install the Rust toolchain via actions-rust-lang/setup-rust-toolchain@v1 (driven by rust-toolchain.toml).

Simplifies build.yml and release.yml by removing Docker Buildx/login/build-and-push steps and instead performing a cargo build --release --locked --bin jito-shredstream-proxy; release.yml now stages target/release/jito-shredstream-proxy as jito-shredstream-proxy-x86_64-unknown-linux-gnu for action-gh-release upload.

Reviewed by Cursor Bugbot for commit 66de22d. Bugbot is set up for automated code reviews on this repo. Configure here.

McSim85 and others added 2 commits May 11, 2026 18:11
Three independent problems prevented these workflows from running on
quiknode-labs/shredstream-proxy:

1. **Custom self-hosted runner**: all three workflows used
   `ubuntu-22.04-16c-64g-public`, which is Jito's private runner pool.
   The fork has no access — jobs would queue indefinitely.

2. **Missing Rust toolchain**: the `setup-rust` composite action only
   installed protoc and assumed rustc was already present on the runner
   (true on Jito's custom runner). Stock GitHub-hosted runners ship
   rustup but no specific toolchain; the build would fail to find 1.84.

3. **Hardcoded Docker Hub push**: build.yml and release.yml pushed to
   `jitolabs/jito-shredstream-proxy:*` using `secrets.DOCKERHUB_USER` /
   `secrets.DOCKERHUB_PWD`. Those secrets don't exist on the fork and
   shouldn't — they're Jito's. The QN deploy pipeline pulls binaries
   from an OCI bucket via the `role_chain_build` Drone pipeline, so the
   Docker Hub path is irrelevant for QN production deploys.

Changes:

- `setup-rust/action.yaml`: add `dtolnay/rust-toolchain@1.84` step to
  explicitly install the toolchain pinned in `rust-toolchain.toml`.
  Stays compatible with self-hosted runners that already have rust.

- `test.yml` / `build.yml`: switch to stock `ubuntu-22.04` runner.
  Drop Docker login/build/push from build.yml — clippy + a fresh
  `cargo build --release` cover the PR-validation purpose without
  publishing artifacts anywhere.

- `release.yml`: switch to stock runner. Replace the Docker-based
  binary extraction (build image → push to Docker Hub → docker run cat)
  with a direct `cargo build --release`. The resulting binary is
  staged as `jito-shredstream-proxy-x86_64-unknown-linux-gnu` and
  uploaded to the GitHub Release by `softprops/action-gh-release@v2`
  on tag push — same artifact name as before, no behavior change for
  consumers reading the Release page.

Dropped multi-arch (arm64) builds since the QN fleet is x86_64-only
(znver3/4/5 targets per `role_chain_build`). If arm64 is ever needed,
re-add via `cross` or QEMU.

Note: Actions must be enabled on the fork (Settings → Actions → General
→ "Allow all actions and reusable workflows") for any of these to run.
That's a one-time manual click — no PR can do it.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Switches the Rust install step from dtolnay/rust-toolchain@1.84 to
actions-rust-lang/setup-rust-toolchain@v1, which reads rust-toolchain.toml
when no explicit toolchain input is given.

Why this matters: the previous version hardcoded `@1.84` and only declared
`components: rustfmt, clippy` — duplicating the source of truth held by
`rust-toolchain.toml` (`channel = "1.84"`, components `[rustfmt, rustc-dev,
clippy, cargo]`). Bumping the toml without also bumping the action would
silently leave CI on the old toolchain, producing local/CI drift that's
painful to diagnose. With this change, `rust-toolchain.toml` is the only
place to edit.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 66de22d. Configure here.

Comment thread .github/actions/setup-rust/action.yaml
actions-rust-lang/setup-rust-toolchain@v1 already enables Swatinem/rust-cache
by default, which caches ~/.cargo and target/ using Rust-aware logic
(workspace member detection, smart target invalidation on dependency
changes, garbage collection). The composite action also had two explicit
actions/cache@v4 steps caching the same paths — two systems independently
saving and restoring overlapping directories, causing cache conflicts,
stale restores, and wasted GHA cache storage.

Fix: remove the manual actions/cache@v4 steps. Swatinem/rust-cache is
strictly better than the previous naive ~/.cargo + target/ caching for
this workload — the same paths get cached, but with smarter keys.

Followups that became unnecessary:
- The `caller-workflow-name` input only existed to feed the cache-key
  generator. Now unused; removed from the action interface and from
  the three callers (test.yml, build.yml, release.yml).
- The "Generate cache key" and "Check cache key" steps are gone.

Net: 9 lines added, 37 removed. Simpler action, no behavior change
besides faster and more correct caching.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@McSim85 McSim85 requested a review from a team May 12, 2026 17:42
@McSim85 McSim85 merged commit c0cc3a5 into main-qn May 12, 2026
2 checks passed
@McSim85 McSim85 deleted the qn/ci-make-runnable-on-fork branch May 12, 2026 17:58
McSim85 added a commit that referenced this pull request May 12, 2026
Adds two sections to CONTRIBUTING.md that became relevant after PR #4
(CI fixes) landed and branch protection rulesets were configured:

- "What's currently QN-specific" — lists the three categories of changes
  on main-qn that diverge from upstream: the metric label patch (eligible
  for upstream), the CI workflow overrides (fork-specific), and the
  policy docs themselves. Future contributors can use this as a
  reference for what "broadly useful" looks like vs "QN-only".

- "Branch protection" — explains the two rulesets (master-mirror-lock
  and main-qn-pr-review), why direct pushes to master fail, and which
  CI checks must pass on PRs to main-qn.

No content changes elsewhere in the doc — the two-branch model and
gh CLI invocations are unchanged.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
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