Skip to content

Commit 6c45365

Browse files
fix: daily CI pipeline configuration (#1063)
* fix: add missing image property to daily CI pool config The 1ES Pipeline Templates require the pool to specify an image that matches the os property. Added 'image: ubuntu-latest' to resolve the pipeline validation error. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * fix: switch daily CI pool to Windows to avoid network isolation 1ES PT enforces container-based network isolation on Linux pools, which blocks dotnet restore from reaching NuGet.org. Switching to Windows (matching the release pipeline) avoids this issue. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * fix: use Azure Artifacts feed to bypass network isolation The Azure-Pipelines-1ESPT-ExDShared pool enforces network isolation, blocking access to nuget.org. Added a nuget.config pointing to the GraphDeveloperExperiences_Public Azure Artifacts feed and added a NuGetAuthenticate step to provide credentials for the feed. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * fix: install both .NET 8 and .NET 10 SDKs in daily CI The test project targets net462, net8.0, and net10.0. The previous config only installed the SDK from global.json (.NET 10), causing test runs to abort for net8.0. Now explicitly installs both .NET 8 and .NET 10, matching the production build pipeline. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * refactor: generate nuget.config inline instead of committing to repo Move the nuget.config creation into an inline PowerShell step in the pipeline so the feed configuration is self-contained in the CI file. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * refactor: use NUGET_FEED_URI variable for feed URL Extract the Azure Artifacts feed URI into a pipeline variable so it can be easily referenced and overridden. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * fix: remove inline NUGET_FEED_URI variable, set via ADO UI Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent 068aea8 commit 6c45365

1 file changed

Lines changed: 26 additions & 4 deletions

File tree

.azure-pipelines/daily-ci-build.yml

Lines changed: 26 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ extends:
2121
parameters:
2222
pool:
2323
name: Azure-Pipelines-1ESPT-ExDShared
24-
os: linux
24+
image: windows-latest
25+
os: windows
2526
sdl:
2627
sourceAnalysisPool:
2728
name: Azure-Pipelines-1ESPT-ExDShared
@@ -43,12 +44,33 @@ extends:
4344
submodules: recursive
4445

4546
- task: UseDotNet@2
46-
displayName: Set up .NET
47+
displayName: Set up .NET 8
4748
inputs:
4849
packageType: 'sdk'
49-
useGlobalJson: true
50+
version: 8.x
5051

51-
- script: dotnet restore Microsoft.Graph.Core.sln
52+
- task: UseDotNet@2
53+
displayName: Set up .NET 10
54+
inputs:
55+
packageType: 'sdk'
56+
version: 10.x
57+
58+
- task: NuGetAuthenticate@1
59+
displayName: Authenticate to Azure Artifacts
60+
61+
- powershell: |
62+
@"
63+
<?xml version="1.0" encoding="utf-8"?>
64+
<configuration>
65+
<packageSources>
66+
<clear />
67+
<add key="GraphDeveloperExperiences_Public" value="$(NUGET_FEED_URI)" />
68+
</packageSources>
69+
</configuration>
70+
"@ | Set-Content -Path "$(Build.SourcesDirectory)\nuget.config" -Encoding UTF8
71+
displayName: Create nuget.config
72+
73+
- script: dotnet restore Microsoft.Graph.Core.sln --configfile nuget.config
5274
displayName: Restore dependencies
5375
workingDirectory: $(Build.SourcesDirectory)
5476

0 commit comments

Comments
 (0)