From 0594311c035695df14e7f36e0d9b15ce1c82db79 Mon Sep 17 00:00:00 2001 From: Jeremy Koritzinsky Date: Wed, 21 Jan 2026 23:02:17 +0000 Subject: [PATCH 1/5] Set up feed credentials for internal validation PR pipeline --- .../common/templates/runtimes/xplat-job.yml | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/eng/pipelines/common/templates/runtimes/xplat-job.yml b/eng/pipelines/common/templates/runtimes/xplat-job.yml index 00e8dfb520a101..ad54a97cdd21cf 100644 --- a/eng/pipelines/common/templates/runtimes/xplat-job.yml +++ b/eng/pipelines/common/templates/runtimes/xplat-job.yml @@ -109,4 +109,29 @@ jobs: fetchDepth: $(checkoutFetchDepth) fetchTags: false + - ${{ if and(eq(parameters.isOfficialBuild, true), notin(parameters.osGroup, 'osx', 'maccatalyst', 'ios', 'iossimulator', 'tvos', 'tvossimulator')) }}: + - template: /eng/pipelines/common/restore-internal-tools.yml + + - ${{ if ne(variables['System.TeamProject'], 'public') }}: + - ${{ if and(ne(parameters.osGroup, 'windows'), ne(parameters.hostedOs, 'windows')) }}: + - task: Bash@3 + displayName: Setup Private Feeds Credentials + inputs: + filePath: $(Build.SourcesDirectory)/eng/common/SetupNugetSources.sh + arguments: $(Build.SourcesDirectory)/NuGet.config $Token + env: + Token: $(dn-bot-dnceng-artifact-feeds-rw) + - ${{ else }}: + - task: PowerShell@2 + displayName: Setup Private Feeds Credentials + inputs: + filePath: $(Build.SourcesDirectory)/eng/common/SetupNugetSources.ps1 + arguments: -ConfigFile $(Build.SourcesDirectory)/NuGet.config -Password $Env:Token + env: + Token: $(dn-bot-dnceng-artifact-feeds-rw) + # Run the NuGetAuthenticate task after the internal feeds are added to the nuget.config + # This ensures that creds are set appropriately for all feeds in the config, and that the + # credential provider is installed. + - task: NuGetAuthenticate@1 + - ${{ parameters.steps }} From 9ff47bd8d5961cdc25f8c68f822ca5a8244215b6 Mon Sep 17 00:00:00 2001 From: Jeremy Koritzinsky Date: Wed, 21 Jan 2026 23:07:03 +0000 Subject: [PATCH 2/5] Fix the open/internal split for runtime helix queues --- .../coreclr/templates/helix-queues-setup.yml | 35 +++++++++++++++---- 1 file changed, 28 insertions(+), 7 deletions(-) diff --git a/eng/pipelines/coreclr/templates/helix-queues-setup.yml b/eng/pipelines/coreclr/templates/helix-queues-setup.yml index 3a71e6e0ecb611..f2e7b6e6fde5bf 100644 --- a/eng/pipelines/coreclr/templates/helix-queues-setup.yml +++ b/eng/pipelines/coreclr/templates/helix-queues-setup.yml @@ -34,31 +34,52 @@ jobs: # iOS Simulator/Mac Catalyst arm64 - ${{ if in(parameters.platform, 'iossimulator_arm64', 'tvossimulator_arm64', 'maccatalyst_arm64') }}: - - OSX.15.Arm64.Open + - ${{ if eq(variables['System.TeamProject'], 'public') }}: + - OSX.15.Arm64.Open + - ${{ if eq(variables['System.TeamProject'], 'internal') }}: + - OSX.15.Arm64 # iOS/tvOS Simulator x64 & MacCatalyst x64 - ${{ if in(parameters.platform, 'iossimulator_x64', 'tvossimulator_x64', 'maccatalyst_x64') }}: - - OSX.15.Amd64.Open + - ${{ if eq(variables['System.TeamProject'], 'public') }}: + - OSX.15.Amd64.Open + - ${{ if eq(variables['System.TeamProject'], 'internal') }}: + - OSX.15.Amd64 # Android arm64 - ${{ if in(parameters.platform, 'android_arm64') }}: - - Windows.11.Amd64.Android.Open + - ${{ if eq(variables['System.TeamProject'], 'public') }}: + - Windows.11.Amd64.Android.Open + - ${{ if eq(variables['System.TeamProject'], 'internal') }}: + - Windows.11.Amd64.Android # Android x64 - ${{ if in(parameters.platform, 'android_x64') }}: - - Ubuntu.2204.Amd64.Android.29.Open + - ${{ if eq(variables['System.TeamProject'], 'public') }}: + - Ubuntu.2204.Amd64.Android.29.Open + - ${{ if eq(variables['System.TeamProject'], 'internal') }}: + - Ubuntu.2204.Amd64.Android.29 # Browser wasm - ${{ if eq(parameters.platform, 'browser_wasm') }}: - - (Ubuntu.2404.Amd64)AzureLinux.3.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-24.04-helix-webassembly-amd64 + - ${{ if eq(variables['System.TeamProject'], 'public') }}: + - (Ubuntu.2404.Amd64)AzureLinux.3.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-24.04-helix-webassembly-amd64 + - ${{ if eq(variables['System.TeamProject'], 'internal') }}: + - (Ubuntu.2404.Amd64)AzureLinux.3.Amd64@mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-24.04-helix-webassembly-amd64 # iOS devices - ${{ if in(parameters.platform, 'ios_arm64') }}: - - osx.15.amd64.iphone.open + - ${{ if eq(variables['System.TeamProject'], 'public') }}: + - osx.15.amd64.iphone.open + - ${{ if eq(variables['System.TeamProject'], 'internal') }}: + - osx.15.amd64.iphone # tvOS devices - ${{ if in(parameters.platform, 'tvos_arm64') }}: - - osx.15.amd64.appletv.open + - ${{ if eq(variables['System.TeamProject'], 'public') }}: + - osx.15.amd64.appletv.open + - ${{ if eq(variables['System.TeamProject'], 'internal') }}: + - osx.15.amd64.appletv # Linux arm - ${{ if eq(parameters.platform, 'linux_arm') }}: From 6bd5370e91e170fff676ceb15a21c7deea2a7fb0 Mon Sep 17 00:00:00 2001 From: Jeremy Koritzinsky Date: Wed, 21 Jan 2026 23:12:39 +0000 Subject: [PATCH 3/5] Hack around lack of a corresponding internal queue for Android --- eng/pipelines/libraries/helix-queues-setup.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/eng/pipelines/libraries/helix-queues-setup.yml b/eng/pipelines/libraries/helix-queues-setup.yml index 6438a288f70681..3a018bc981d364 100644 --- a/eng/pipelines/libraries/helix-queues-setup.yml +++ b/eng/pipelines/libraries/helix-queues-setup.yml @@ -85,9 +85,11 @@ jobs: - $(helix_macos_x64) # Android - - ${{ if in(parameters.platform, 'android_x86', 'android_x64', 'linux_bionic_x64') }}: + # Always use the Ubuntu-based Android queue for internal validation as there is no internal equivalent of + # the Windows.11.Amd64.Android.Open queue. + - ${{ if or(eq(variables['System.TeamProject'], 'internal'), in(parameters.platform, 'android_x86', 'android_x64', 'linux_bionic_x64')) }}: - Ubuntu.2204.Amd64.Android.29.Open - - ${{ if in(parameters.platform, 'android_arm', 'android_arm64', 'linux_bionic_arm', 'linux_bionic_arm64') }}: + - ${{ if and(eq(variables['System.TeamProject'], 'public'), in(parameters.platform, 'android_arm', 'android_arm64', 'linux_bionic_arm', 'linux_bionic_arm64')) }}: - Windows.11.Amd64.Android.Open # iOS Simulator/Mac Catalyst arm64 From a1bbd2003f7c73966d83ce21d67216e5261079e1 Mon Sep 17 00:00:00 2001 From: Jeremy Koritzinsky Date: Fri, 23 Jan 2026 14:57:39 -0800 Subject: [PATCH 4/5] Do a little cleanup --- eng/pipelines/common/templates/runtimes/xplat-job.yml | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/eng/pipelines/common/templates/runtimes/xplat-job.yml b/eng/pipelines/common/templates/runtimes/xplat-job.yml index ad54a97cdd21cf..3b5ed2f0a1d97c 100644 --- a/eng/pipelines/common/templates/runtimes/xplat-job.yml +++ b/eng/pipelines/common/templates/runtimes/xplat-job.yml @@ -109,11 +109,8 @@ jobs: fetchDepth: $(checkoutFetchDepth) fetchTags: false - - ${{ if and(eq(parameters.isOfficialBuild, true), notin(parameters.osGroup, 'osx', 'maccatalyst', 'ios', 'iossimulator', 'tvos', 'tvossimulator')) }}: - - template: /eng/pipelines/common/restore-internal-tools.yml - - ${{ if ne(variables['System.TeamProject'], 'public') }}: - - ${{ if and(ne(parameters.osGroup, 'windows'), ne(parameters.hostedOs, 'windows')) }}: + - ${{ if and(ne(parameters.osGroup, 'windows')) }}: - task: Bash@3 displayName: Setup Private Feeds Credentials inputs: From c9168e6de5b1ece8bc7b95576452e0329e749edd Mon Sep 17 00:00:00 2001 From: Jeremy Koritzinsky Date: Mon, 26 Jan 2026 16:47:23 -0800 Subject: [PATCH 5/5] Use shared template for enabling internal sources --- eng/pipelines/common/global-build-job.yml | 22 +--------------- .../common/templates/runtimes/xplat-job.yml | 22 +--------------- .../diagnostics/runtime-diag-job.yml | 22 +--------------- eng/pipelines/libraries/run-test-job.yml | 25 +++---------------- 4 files changed, 6 insertions(+), 85 deletions(-) diff --git a/eng/pipelines/common/global-build-job.yml b/eng/pipelines/common/global-build-job.yml index afdbeff1c3154e..f6d09760772a26 100644 --- a/eng/pipelines/common/global-build-job.yml +++ b/eng/pipelines/common/global-build-job.yml @@ -172,27 +172,7 @@ jobs: - ${{ if and(eq(parameters.isOfficialBuild, true), notin(parameters.osGroup, 'osx', 'maccatalyst', 'ios', 'iossimulator', 'tvos', 'tvossimulator')) }}: - template: /eng/pipelines/common/restore-internal-tools.yml - - ${{ if ne(variables['System.TeamProject'], 'public') }}: - - ${{ if and(ne(parameters.osGroup, 'windows'), ne(parameters.hostedOs, 'windows')) }}: - - task: Bash@3 - displayName: Setup Private Feeds Credentials - inputs: - filePath: $(Build.SourcesDirectory)/eng/common/SetupNugetSources.sh - arguments: $(Build.SourcesDirectory)/NuGet.config $Token - env: - Token: $(dn-bot-dnceng-artifact-feeds-rw) - - ${{ else }}: - - task: PowerShell@2 - displayName: Setup Private Feeds Credentials - inputs: - filePath: $(Build.SourcesDirectory)/eng/common/SetupNugetSources.ps1 - arguments: -ConfigFile $(Build.SourcesDirectory)/NuGet.config -Password $Env:Token - env: - Token: $(dn-bot-dnceng-artifact-feeds-rw) - # Run the NuGetAuthenticate task after the internal feeds are added to the nuget.config - # This ensures that creds are set appropriately for all feeds in the config, and that the - # credential provider is installed. - - task: NuGetAuthenticate@1 + - template: /eng/common/${{ parameters.templatePath }}/steps/enable-internal-sources.yml - ${{ if in(parameters.osGroup, 'osx', 'maccatalyst', 'ios', 'iossimulator', 'tvos', 'tvossimulator') }}: - script: $(Build.SourcesDirectory)/eng/common/native/install-dependencies.sh ${{ parameters.osGroup }} diff --git a/eng/pipelines/common/templates/runtimes/xplat-job.yml b/eng/pipelines/common/templates/runtimes/xplat-job.yml index 3b5ed2f0a1d97c..0e09b929828aed 100644 --- a/eng/pipelines/common/templates/runtimes/xplat-job.yml +++ b/eng/pipelines/common/templates/runtimes/xplat-job.yml @@ -109,26 +109,6 @@ jobs: fetchDepth: $(checkoutFetchDepth) fetchTags: false - - ${{ if ne(variables['System.TeamProject'], 'public') }}: - - ${{ if and(ne(parameters.osGroup, 'windows')) }}: - - task: Bash@3 - displayName: Setup Private Feeds Credentials - inputs: - filePath: $(Build.SourcesDirectory)/eng/common/SetupNugetSources.sh - arguments: $(Build.SourcesDirectory)/NuGet.config $Token - env: - Token: $(dn-bot-dnceng-artifact-feeds-rw) - - ${{ else }}: - - task: PowerShell@2 - displayName: Setup Private Feeds Credentials - inputs: - filePath: $(Build.SourcesDirectory)/eng/common/SetupNugetSources.ps1 - arguments: -ConfigFile $(Build.SourcesDirectory)/NuGet.config -Password $Env:Token - env: - Token: $(dn-bot-dnceng-artifact-feeds-rw) - # Run the NuGetAuthenticate task after the internal feeds are added to the nuget.config - # This ensures that creds are set appropriately for all feeds in the config, and that the - # credential provider is installed. - - task: NuGetAuthenticate@1 + - template: /eng/common/${{ parameters.templatePath }}/steps/enable-internal-sources.yml - ${{ parameters.steps }} diff --git a/eng/pipelines/diagnostics/runtime-diag-job.yml b/eng/pipelines/diagnostics/runtime-diag-job.yml index 85d644e851a8ac..a9421e29b6199d 100644 --- a/eng/pipelines/diagnostics/runtime-diag-job.yml +++ b/eng/pipelines/diagnostics/runtime-diag-job.yml @@ -147,27 +147,7 @@ jobs: - ${{ if and(eq(parameters.isOfficialBuild, true), notin(parameters.osGroup, 'osx', 'maccatalyst', 'ios', 'iossimulator', 'tvos', 'tvossimulator')) }}: - template: /eng/pipelines/common/restore-internal-tools.yml - - ${{ if ne(variables['System.TeamProject'], 'public') }}: - - ${{ if and(ne(parameters.osGroup, 'windows'), ne(parameters.hostedOs, 'windows')) }}: - - task: Bash@3 - displayName: Setup Private Feeds Credentials - inputs: - filePath: $(Build.SourcesDirectory)/eng/common/SetupNugetSources.sh - arguments: $(Build.SourcesDirectory)/NuGet.config $Token - env: - Token: $(dn-bot-dnceng-artifact-feeds-rw) - - ${{ else }}: - - task: PowerShell@2 - displayName: Setup Private Feeds Credentials - inputs: - filePath: $(Build.SourcesDirectory)/eng/common/SetupNugetSources.ps1 - arguments: -ConfigFile $(Build.SourcesDirectory)/NuGet.config -Password $Env:Token - env: - Token: $(dn-bot-dnceng-artifact-feeds-rw) - # Run the NuGetAuthenticate task after the internal feeds are added to the nuget.config - # This ensures that creds are set appropriately for all feeds in the config, and that the - # credential provider is installed. - - task: NuGetAuthenticate@1 + - template: /eng/common/${{ parameters.templatePath }}/steps/enable-internal-sources.yml - ${{ if in(parameters.osGroup, 'osx', 'maccatalyst', 'ios', 'iossimulator', 'tvos', 'tvossimulator') }}: - script: $(Build.SourcesDirectory)/eng/common/native/install-dependencies.sh ${{ parameters.osGroup }} diff --git a/eng/pipelines/libraries/run-test-job.yml b/eng/pipelines/libraries/run-test-job.yml index ed826732c819dd..75f35341da2d97 100644 --- a/eng/pipelines/libraries/run-test-job.yml +++ b/eng/pipelines/libraries/run-test-job.yml @@ -26,9 +26,10 @@ parameters: helixArtifactsName: '' unifiedBuildNameSuffix: '' unifiedBuildConfigOverride: '' + templatePath: 'templates' jobs: - - template: /eng/common/templates/job/job.yml + - template: /eng/common/${{ parameters.templatePath }}/job/job.yml parameters: enablePublishBuildArtifacts: true timeoutInMinutes: ${{ parameters.timeoutInMinutes }} @@ -88,27 +89,7 @@ jobs: fetchDepth: $(checkoutFetchDepth) fetchTags: false - - ${{ if ne(variables['System.TeamProject'], 'public') }}: - - ${{ if ne(parameters.osGroup, 'windows') }}: - - task: Bash@3 - displayName: Setup Private Feeds Credentials - inputs: - filePath: $(Build.SourcesDirectory)/eng/common/SetupNugetSources.sh - arguments: $(Build.SourcesDirectory)/NuGet.config $Token - env: - Token: $(dn-bot-dnceng-artifact-feeds-rw) - - ${{ if eq(parameters.osGroup, 'windows') }}: - - task: PowerShell@2 - displayName: Setup Private Feeds Credentials - inputs: - filePath: $(Build.SourcesDirectory)/eng/common/SetupNugetSources.ps1 - arguments: -ConfigFile $(Build.SourcesDirectory)/NuGet.config -Password $Env:Token - env: - Token: $(dn-bot-dnceng-artifact-feeds-rw) - # Run the NuGetAuthenticate task after the internal feeds are added to the nuget.config - # This ensures that creds are set appropriately for all feeds in the config, and that the - # credential provider is installed. - - task: NuGetAuthenticate@1 + - template: /eng/common/${{ parameters.templatePath }}/steps/enable-internal-sources.yml - ${{ if in(parameters.osGroup, 'osx', 'maccatalyst', 'ios', 'iossimulator', 'tvos', 'tvossimulator') }}: - script: $(Build.SourcesDirectory)/eng/common/native/install-dependencies.sh ${{ parameters.osGroup }}