Skip to content

SAN: publish @linqapp/cli to npm via OIDC trusted publishing#34

Closed
abhiramkast wants to merge 1 commit into
mainfrom
san-163-npm-trusted-publisher
Closed

SAN: publish @linqapp/cli to npm via OIDC trusted publishing#34
abhiramkast wants to merge 1 commit into
mainfrom
san-163-npm-trusted-publisher

Conversation

@abhiramkast

@abhiramkast abhiramkast commented May 22, 2026

Copy link
Copy Markdown
Contributor

Problem

The CLI is only distributed via curl | sudo install today. Enterprise / corp-network users get blocked on unsigned curl-pipe-sh, and we have no npm channel for devs. We also have no provenance signing on releases.

Solution

Enable npm publishing on every main release via npm's OIDC Trusted Publishing — no NPM_TOKEN secret needed, provenance attestations attached automatically.

  • Flip @semantic-release/npm to npmPublish: true.
  • Add id-token: write permission so GitHub issues an OIDC token for the workflow.
  • Drop NPM_TOKEN from the env block.
  • Pin npm to latest in CI (Trusted Publishing requires npm CLI ≥ 11.5.1; Node 22 LTS doesn't always ship that).

Pre-merge requirement

Register the trusted publisher on npmjs.com before this PR is merged. Once merged, the next release will try to publish via OIDC immediately — if the trusted publisher isn't registered yet, that release fails the auth handshake.

At https://www.npmjs.com/package/@linqapp/cli → Settings → Trusted Publishers:

  • Organization: linq-team
  • Repository: linq-cli
  • Workflow filename: release.yml
  • Environment: (leave blank)
  • Allowed actions: npm publish

Confirm registration is saved, then this PR can be merged. The NPM_TOKEN GitHub Actions secret can be deleted after the first successful publish.

🔗 Linear Issue

@abhiramkast
abhiramkast requested a review from jflayhart as a code owner May 22, 2026 17:20
@abhiramkast

Copy link
Copy Markdown
Contributor Author

Done by Josh in a different PR

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.

1 participant