fix: resolve daily CI build failures (1ES pool image + npm auth)#583
Merged
Conversation
The daily CI build was failing because the main pool was missing the required 'image' property. 1ES Pipeline Templates require name, image, and os to all be specified and consistent. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Add .npmrc pointing to GraphDeveloperExperiences_Public Azure Artifacts feed and npmAuthenticate task to the daily CI pipeline to resolve EPERM errors caused by network isolation policies. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The committed .npmrc broke GitHub Actions since it redirects npm to an Azure Artifacts feed that GHA can't authenticate against. Instead, generate the .npmrc at build time only in the ADO pipeline. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
ramsessanchez
added a commit
to microsoftgraph/msgraph-beta-sdk-typescript
that referenced
this pull request
Jun 5, 2026
Aligns with updated approach in microsoftgraph/msgraph-sdk-typescript-core#583. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Extract the hardcoded npm registry URL in the daily CI pipeline into an ADO pipeline variable (npmRegistryUrl) so it can be overridden at queue time. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Map the npmRegistryUrl pipeline variable to an NPM_REGISTRY_URL env var in the script step. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The variable should be set externally via ADO pipeline variables or a variable group, not defined in the YAML. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The ADO variable is already named NPM_REGISTRY_URL, so it can be referenced directly with $(NPM_REGISTRY_URL) without an env block. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
adrian05-ms
previously approved these changes
Jun 5, 2026
Replace the manual .npmrc creation, npmAuthenticate, and npm ci script steps with a single npm@1 task using customRegistry/customFeed. This removes the need for an .npmrc file and the NPM_REGISTRY_URL variable. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
ramsessanchez
added a commit
to microsoftgraph/msgraph-beta-sdk-typescript
that referenced
this pull request
Jun 5, 2026
Replace .npmrc creation + npmAuthenticate@0 + script npm ci with a single npm@1 task using customRegistry/customFeed, matching the approach from microsoftgraph/msgraph-sdk-typescript-core#583. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
9 tasks
ramsessanchez
added a commit
to microsoftgraph/msgraph-sdk-typescript
that referenced
this pull request
Jun 29, 2026
Replace the 3-step .npmrc creation, npmAuthenticate, and npm ci script with a single npm@1 task using customRegistry/customFeed, matching the pattern from microsoftgraph/msgraph-sdk-typescript-core#583. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
ramsessanchez
added a commit
to microsoftgraph/msgraph-beta-sdk-typescript
that referenced
this pull request
Jun 29, 2026
* fix: resolve daily CI build failures (1ES pool image + npm auth) - Add missing 'image: ubuntu-latest' to main pool configuration - Add .npmrc pointing to GraphDeveloperExperiences_Public Azure Artifacts feed - Add npmAuthenticate@0 task before npm ci in the pipeline Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * fix: generate .npmrc inline in pipeline instead of committing it Aligns with updated approach in microsoftgraph/msgraph-sdk-typescript-core#583. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * fix: remove test step from daily CI build pipeline Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * fix: use ADO variable for npm registry URL in daily CI build Replace hardcoded Azure Artifacts registry URL with ADO pipeline variable, matching the approach in msgraph-sdk-typescript-core PR #583. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * fix: use ADO variable directly without env mapping Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * fix: use npm@1 task with Azure Artifacts feed for daily CI build Replace .npmrc creation + npmAuthenticate@0 + script npm ci with a single npm@1 task using customRegistry/customFeed, matching the approach from microsoftgraph/msgraph-sdk-typescript-core#583. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
adrian05-ms
approved these changes
Jun 29, 2026
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
Fixes the daily CI build pipeline which was failing due to two issues:
1. Missing
imageproperty in pool configThe 1ES Pipeline Templates require
name,image, andosto all be specified. The main pool was missing theimageproperty, causing:Fix: Added
image: ubuntu-latestto the main pool configuration.2. npm registry auth for network isolation
Under 1ES network isolation policies, direct access to
registry.npmjs.orgis blocked, causing:Fix:
.npmrcinline at build time (not committed to the repo) pointing to theGraphDeveloperExperiences_PublicAzure Artifacts feednpmAuthenticate@0task beforenpm ciin the pipelineThis approach avoids committing an
.npmrcto the repo, which would break the GitHub Actions workflow that authenticates directly againstregistry.npmjs.org.