feat: Complete public package publishing and pnpm installation flow - #1
Merged
Conversation
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.
Summary
This PR completes the first public FPM package publishing and pnpm installation path.
The registry now accepts the existing
fpm_...personal access tokens as Bearer credentials while retaining browser JWT/cookie authentication. Publishing remains restricted to organization members, package versions are immutable, and commit verifies the upload session owner, manifest identity, SemVer, SHA-256 format, and object-storage presence.A new independent
@fuyeor/fpm-clipackage underpackages/cli/publishes source packages throughacquire -> presigned PUT -> commit. It uses Node.js 24.19.0+, TypeScript/ESM, native fetch, a small tar-stream/zlib packer,.gitignore, manifestfiles, and workspace dependency normalization. It does not use npm legacyPUT /packageor execute unknown lifecycle scripts.The registry exposes npm-compatible Minimal Abbreviated Metadata and a liveness endpoint. Metadata derives
latestfrom the highest valid SemVer and points pnpm to public R2 tarballs atpackages/@scope/name/version.tgz. The staging Dockerfile, Compose file, environment template, README, andSTAGING.mddocument deployment through nginx/v1.Verification
24.19.0+ pnpm11.22.0: CLI build passed.pnpm add @demo/install-fixture, exact-version install, and repeatedpnpm installpassed.cargo fmt --check,cargo check --workspace, andcargo test --workspace: passed; 3 backend unit tests passed.cargo build --release --workspace: passed.pnpm install --frozen-lockfilewith pnpm11.22.0: passed.Staging follow-up
The sandbox does not provide a Docker daemon or the staging PostgreSQL/R2 credentials, so the real Docker image build and real object-storage publish must be executed on the Docker host. Follow
STAGING.mdto apply migrations, start the service, check/v1/health, publish a real package, and validate the three required pnpm commands.Scope notes
This PR supports public downloads and existing organization-member publish permissions. Package-level access-control settings, unpublish/deprecation, dist-tags beyond
latest, binary artifacts, and the full install/consumer protocol remain follow-up work.