Skip to content

[ci] Fix network isolation requirements - #11701

Merged
jonathanpeppers merged 4 commits into
mainfrom
dev/alex/networkiso
Jun 22, 2026
Merged

jonathanpeppers merged 4 commits into
mainfrom
dev/alex/networkiso

Conversation

@dalexsoto

@dalexsoto dalexsoto commented Jun 18, 2026 •

Copy link
Copy Markdown
Member

This pull request makes several updates to the build automation configuration, primarily focused on improving network isolation, updating package sources, and ensuring compatibility with Azure DevOps pipelines. The most important changes are grouped below:

Network Isolation Improvements:

  • Added variables DOTNET_CLI_WORKLOAD_UPDATE_NOTIFY_DISABLE and DOTNET_SDK_VULNERABILITY_CHECK_DISABLE in variables.yaml to address network isolation requirements and disable certain .NET notifications and vulnerability checks.

Package Source Updates:

  • Changed the NuGet source for installing .NET tools in install-dotnet-tool.yaml from the public NuGet feed to the internal Azure DevOps feed (dotnet-public).
  • Updated the darc tool installation in azure-pipelines.yaml to use --source instead of the deprecated --add-source parameter, aligning with current .NET CLI conventions.

These changes help ensure builds are more reliable in isolated network environments and modernize the way .NET tools are installed.

Copilot AI review requested due to automatic review settings June 18, 2026 19:23
@dalexsoto
dalexsoto requested a review from simonrozsival as a code owner June 18, 2026 19:23

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the Azure Pipelines CI configuration to better comply with network isolation requirements by disabling .NET SDK background network checks and ensuring dotnet tool installs/updates use restricted NuGet feeds rather than api.nuget.org.

Changes:

  • Add DOTNET_CLI_WORKLOAD_UPDATE_NOTIFY_DISABLE and DOTNET_SDK_VULNERABILITY_CHECK_DISABLE to CI variables.
  • Update the shared dotnet-tool install template to use an isolated NuGet.config via --configfile (removing --add-source https://api.nuget.org/v3/index.json).
  • Update the darc tool update step to use PowerShell Core and an isolated NuGet.config via --configfile.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
build-tools/automation/yaml-templates/variables.yaml Adds env vars to disable workload update notifications and SDK vulnerability checks to reduce network egress under isolation.
build-tools/automation/yaml-templates/install-dotnet-tool.yaml Writes and uses an isolated NuGet.config for dotnet tool update to avoid nuget.org access.
build-tools/automation/azure-pipelines.yaml Switches darc AzureCLI script to PowerShell Core and uses a cleared-source NuGet.config for darc tool update.

Comment thread build-tools/automation/yaml-templates/install-dotnet-tool.yaml Outdated
Comment thread build-tools/automation/azure-pipelines.yaml Outdated
Comment thread build-tools/automation/yaml-templates/install-dotnet-tool.yaml Outdated
Comment thread build-tools/automation/azure-pipelines.yaml Outdated
Address review feedback: '--source' clears default feeds and points only at the
required dnceng feed, so we don't need to write a temp NuGet.config and pass
'--configfile'.

- install-dotnet-tool.yaml (apkdiff, dotnet-test-slicer): only 'dotnet-public'
  is needed; both tools live on that mirror.
- azure-pipelines.yaml (microsoft.dotnet.darc): still needs 'dotnet-eng',
  which is the only feed darc is published to.

Co-authored-by: Copilot <[email protected]>
@jonathanpeppers

Copy link
Copy Markdown
Member

Switched to --source and dropped the temp NuGet.config / --configfile plumbing in both spots:

  • install-dotnet-tool.yaml — apkdiff and dotnet-test-slicer are both published to dotnet-public (verified via the dnceng feed), so a single --source pointing at dotnet-public is enough. No need for dotnet-eng or dotnet-tools here.
  • azure-pipelines.yaml (darc step) — microsoft.dotnet.darc is not in dotnet-public; it's only on dotnet-eng, so that one keeps --source set to the dotnet-eng feed.

Pushed as 265fbc5.

jonathanpeppers and others added 2 commits June 18, 2026 16:34
No longer need pscore now that the inline script doesn't write a temp NuGet.config.

Co-authored-by: Copilot <[email protected]>
@jonathanpeppers
jonathanpeppers merged commit fa00357 into main Jun 22, 2026
37 of 40 checks passed
@jonathanpeppers
jonathanpeppers deleted the dev/alex/networkiso branch June 22, 2026 14:34
@github-actions github-actions Bot locked and limited conversation to collaborators Jul 23, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants