Skip to content

ci: publish with NPM_TOKEN and run OSV on Mac minis - #182

Merged
joeblau merged 1 commit into
mainfrom
cursor/self-hosted-npm-token-c940
Oct 18, 2026
Merged

joeblau merged 1 commit into
mainfrom
cursor/self-hosted-npm-token-c940

Conversation

@joeblau

@joeblau joeblau commented Oct 18, 2026

Copy link
Copy Markdown

This loses npm trusted publishing and provenance. Official npm docs say trusted publishing supports GitHub-hosted runners only; self-hosted runners are not supported (Trusted publishing for npm packages). Per Joe's decision (same tradeoff as bloxwap/font#14), publish stays on the Mac minis and authenticates with the org-level NPM_TOKEN secret (NODE_AUTH_TOKEN) instead of OIDC.

What changed

  • publish already used runs-on: [self-hosted, macOS, ARM64] (runner group JWS). id-token: write is removed because OIDC trusted publishing cannot work here.
  • Auth is NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}. Joe's org-level granular token (publish rights for @bloxwap packages) is already shared with this repo.
  • actions/setup-node now sets registry-url: https://registry.npmjs.org so npm uses that token. Build, tag selection, and npm publish --access public are unchanged.
  • The job fails closed if NPM_TOKEN is missing and never prints the token.

OSV scan also moved off GitHub-hosted Ubuntu

security.yml no longer calls google/osv-scanner-action's reusable workflow (that callee pins runs-on: ubuntu-latest and a Linux container). The job now runs on the Mac minis with the same OSV-Scanner v2.3.8 darwin_arm64 binary (SHA256-verified), the same two lockfiles, and the same fail-on-vuln behavior. Results still upload as an artifact. SARIF upload stays disabled.

Docs

docs/ci-runners.md now says every job is on the minis, and that publish uses NPM_TOKEN without provenance.

Do not merge until CI is green. This PR does not merge itself.

Open in Web Open in Cursor 

npm trusted publishing does not support self-hosted runners, so the
publish job now authenticates with the org-level NPM_TOKEN secret.
The OSV scan no longer calls Google's ubuntu-latest reusable workflow;
it runs the same v2.3.8 scanner binary on the Mac minis.

Co-authored-by: Joe Blau <[email protected]>
@joeblau
joeblau marked this pull request as ready for review October 18, 2026 17:43
@joeblau
joeblau merged commit 3ce98ef into main Oct 18, 2026
5 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