Skip to content

Commit d803d1b

Browse files
authored
Fix DevEx and IDDP builds (#3093)
* Fix build * Nuget authenticate without source * resilience to jobs * Cleaner way to remove the external feed and add the internal one * Adding a display
1 parent ef06ec5 commit d803d1b

File tree

4 files changed

+8
-18
lines changed

4 files changed

+8
-18
lines changed

build/template-install-dependencies.yaml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
#template-install-dependencies.yaml
2-
parameters:
3-
authenticateForFeed: 'true'
42

53
#install dotnet core
64

@@ -48,9 +46,6 @@ steps:
4846

4947
- task: NuGetAuthenticate@1
5048
displayName: NuGet Authenticate
51-
condition: eq('${{ parameters.authenticateForFeed }}', 'true')
52-
inputs:
53-
nuGetServiceConnections: 'IDDP Feed'
5449

5550
- powershell: |
5651
$kvSecretBytes = [System.Convert]::FromBase64String('$(LabAuth)')

build/template-onebranch-release-build.yaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@ steps:
99

1010
# Bootstrap the build
1111
- template: template-install-dependencies.yaml
12-
parameters:
13-
authenticateForFeed: 'false'
1412

1513
# Nuget Restore and Build Microsoft.Identity.Web.sln
1614
- template: template-restore-build-MSIdentityWeb.yaml

build/template-pack-nuget.yaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,6 @@ steps:
1616
nobuild: '${{parameters.NoBuild}}'
1717
packagesToPack: '${{ parameters.ProjectRootPath }}\${{ parameters.AssemblyName }}.csproj'
1818
IncludeSymbols: true
19-
feedsToUse: 'config'
20-
nugetConfigPath: NuGet.config
2119
verbosityPack: normal
2220
packDirectory:
2321
arguments: '--configuration ${{ parameters.BuildConfiguration }}'

build/template-restore-build-MSIdentityWeb.yaml

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -11,22 +11,21 @@ steps:
1111
dotnet workload restore $(IdWebSourceDir)tests\DevApps\blazorwasm-b2c\blazorwasm2-b2c.csproj
1212
displayName: 'Install wasm-tools'
1313

14-
- task: NuGetAuthenticate@1
15-
displayName: NuGet Authenticate
16-
inputs:
17-
nuGetServiceConnections: 'IDDP Feed'
18-
19-
- script: dotnet nuget update source NuGet --source https://identitydivision.pkgs.visualstudio.com/_packaging/IDDP/nuget/v3/index.json --configfile "$(Build.SourcesDirectory)\Nuget.config"
20-
displayName: 'Add NuGet Source for MISE'
14+
- powershell: |
15+
$nugetSourceIsExternal = (dotnet nuget list source --format Short).Contains("https://api.nuget.org/v3/index.json")
16+
if ($nugetSourceIsExternal) {
17+
dotnet nuget remove source NuGet
18+
dotnet nuget add source https://identitydivision.pkgs.visualstudio.com/_packaging/IDDP/nuget/v3/index.json -n IDDP
19+
dotnet nuget list source
20+
}
21+
displayName: 'Remove external "NuGet" Source and add "IDDP artifacts" as a NuGet Source, if needed.'
2122

2223
- task: DotNetCoreCLI@2
2324
displayName: 'Build solution Microsoft.Identity.Web.sln'
2425
inputs:
2526
command: 'custom'
2627
custom: 'build'
2728
projects: '$(IdWebSourceDir)Microsoft.Identity.Web.sln'
28-
feedsToUse: 'config'
29-
nugetConfigPath: NuGet.config
3029
arguments: '-p:configuration=${{ parameters.BuildConfiguration }} -p:RunCodeAnalysis=true -p:MicrosoftIdentityWebVersion=${{ parameters.MicrosoftIdentityWebVersion }} -p:SourceLinkCreate=true'
3130

3231
# This task is needed so that the 1CS Rolsyn analyzers task works.

0 commit comments

Comments
 (0)