Skip to content

Fix the npm registry issue in release pipeline#670

Merged
Deekshitha2812 merged 5 commits into
masterfrom
users/deekshitha2812/fix-node-api-relase-pipeline
Jun 8, 2026
Merged

Fix the npm registry issue in release pipeline#670
Deekshitha2812 merged 5 commits into
masterfrom
users/deekshitha2812/fix-node-api-relase-pipeline

Conversation

@Deekshitha2812
Copy link
Copy Markdown
Contributor

@Deekshitha2812 Deekshitha2812 commented May 26, 2026

Problem

The node-api-release pipeline is failing due to 1ES Network Isolation (Enforce mode) blocking outbound connections:

  1. NodeTool@0 step fails for Node 16.x, 18.x — Network Isolation blocks connections to nodejs.org, preventing Node binary downloads.
  2. Upgrade npm step fails for Node 20.x, 22.x, 24.x — Network Isolation (CFSClean policy) blocks connections to registry.npmjs.org, preventing npm install -g npm@8.

Root Cause

  • The pipeline's Network Isolation policy (Preferred,CFSClean) does not include the NodeTool shared policy, which is required to allow downloads from nodejs.org.
  • The CFSClean policy intentionally blocks all public package registries (including registry.npmjs.org) for SFI compliance. The Upgrade npm step (npm install -g npm@8) attempts to download from registry.npmjs.org, which is blocked.

Fix

  1. Added NodeTool to the network isolation policy — Allows nodejs.org access so NodeTool@0 can download Node binaries.
  2. Made npm upgrade conditional — Instead of always running npm install -g npm@(npmversion) (which fails under CFSClean), the step now checks the bundled npm major version and only upgrades if below the required version. Uses --userconfig to read auth from the project .npmrc (set by NpmAuthenticate).
  3. Upgraded NodeTool@0 to UseNode@1 — NodeTool@0 is deprecated; replaced with UseNode@1 (updated versionSpec → version input accordingly).

Testing

@Deekshitha2812
Copy link
Copy Markdown
Contributor Author

/azp run

@Deekshitha2812
Copy link
Copy Markdown
Contributor Author

/azp run

@Deekshitha2812 Deekshitha2812 force-pushed the users/deekshitha2812/fix-node-api-relase-pipeline branch 2 times, most recently from 4a1cf91 to d6e9b02 Compare June 4, 2026 11:13
@Deekshitha2812 Deekshitha2812 force-pushed the users/deekshitha2812/fix-node-api-relase-pipeline branch from d6e9b02 to 0b06403 Compare June 5, 2026 03:55
@Deekshitha2812 Deekshitha2812 marked this pull request as ready for review June 5, 2026 04:12
@Deekshitha2812 Deekshitha2812 requested a review from a team as a code owner June 5, 2026 04:12
@Deekshitha2812
Copy link
Copy Markdown
Contributor Author

/azp run

@Deekshitha2812 Deekshitha2812 force-pushed the users/deekshitha2812/fix-node-api-relase-pipeline branch from cd8b8b6 to 0598d2e Compare June 8, 2026 08:21
@Deekshitha2812 Deekshitha2812 force-pushed the users/deekshitha2812/fix-node-api-relase-pipeline branch from 0598d2e to 99c2c22 Compare June 8, 2026 09:19
@Deekshitha2812
Copy link
Copy Markdown
Contributor Author

/azp run

@Deekshitha2812
Copy link
Copy Markdown
Contributor Author

/azp run

@Deekshitha2812 Deekshitha2812 merged commit 09b922a into master Jun 8, 2026
2 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.

3 participants