diff --git a/eng/pipelines/common/global-build-job.yml b/eng/pipelines/common/global-build-job.yml index 13da1c03fbaf4..1fe318e984fa8 100644 --- a/eng/pipelines/common/global-build-job.yml +++ b/eng/pipelines/common/global-build-job.yml @@ -187,6 +187,10 @@ jobs: 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 - ${{ each monoCrossAOTTargetOS in parameters.monoCrossAOTTargetOS }}: - task: DownloadPipelineArtifact@2 diff --git a/eng/pipelines/libraries/run-test-job.yml b/eng/pipelines/libraries/run-test-job.yml index bc3697359f044..82017494a4bb5 100644 --- a/eng/pipelines/libraries/run-test-job.yml +++ b/eng/pipelines/libraries/run-test-job.yml @@ -104,6 +104,10 @@ jobs: 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 - ${{ if in(parameters.osGroup, 'osx', 'maccatalyst', 'ios', 'iossimulator', 'tvos', 'tvossimulator') }}: - script: $(Build.SourcesDirectory)/eng/install-native-dependencies.sh ${{ parameters.osGroup }}