Skip to content

ci: better DX - #42

Merged
ematipico merged 2 commits into
mainfrom
build/local-pack
Oct 15, 2026
Merged

ematipico merged 2 commits into
mainfrom
build/local-pack

Conversation

@ematipico

Copy link
Copy Markdown
Collaborator

Summary

Makes building and packing @cloudflare/forge the same locally and in CI, using just recipes that CI calls too. Maintainers can produce the full
six-platform tarball locally and copy it into a downstream repository (e.g. cf's vendor/).

just build-all      # all six binaries into target/binaries/ (a Mac plus Docker)
just fetch <run-id> # or: download a publish-preview run's binaries
just pack           # → packages/forge/dist/cloudflare-forge-<version>.tgz

Changes

  • Recipes: build <target> (native cargo), build-docker <target> (Linux musl / Windows MSVC in Docker), build-all, fetch <run-id>, and pack (runs
    archive.mjs). All binaries go through target/binaries/<target>/release/.
  • Docker: docker/release.Dockerfile has a Linux image (Alpine) and a Windows image (cargo-xwin), both with the Rust version from
    rust-toolchain.toml. The images also trust any .crt files in docker/certs/ (gitignored).
  • CI: build jobs run just build, and the pack job runs just pack. Native runners are unchanged.
  • Windows: the static C runtime flag moved from the CI matrix to the justfile, so native and Docker builds share it.
  • Removed: compile.mjs and publish.mjs, plus their package.json scripts.

Testing

  • Built both macOS targets with just build, fetched all six binaries from a CI run with just fetch, and packed them with just pack. The tarball installs
    and forge --version works.
  • Checked that Cargo passes +crt-static to Windows builds started through just.
  • oxfmt, oxlint and actionlint pass.
  • Not yet verified: the real Docker builds, and this PR's CI run.

@pkg-pr-new

pkg-pr-new Bot commented Oct 14, 2026

Copy link
Copy Markdown
npm i https://pkg.pr.new/cloudflare/forge/@cloudflare/forge@42

commit: ba0c424

@ematipico
ematipico merged commit c71948a into main Oct 15, 2026
16 checks passed
@ematipico
ematipico deleted the build/local-pack branch October 15, 2026 04:05
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