Skip to content

Commit 6fc4805

Browse files
committed
Add restore script before build for sbom generation
1 parent 6fbb47e commit 6fc4805

File tree

2 files changed

+17
-0
lines changed

2 files changed

+17
-0
lines changed

azure-pipelines.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,10 @@ stages:
136136
command: custom
137137
custom: '--info'
138138

139+
# Restore internal tools required for SBOM generation
140+
- ${{ if eq(variables._RunAsInternal, True) }}:
141+
- template: /eng/restore-internal-tools.yml
142+
139143
- powershell: eng\common\CIBuild.cmd
140144
-configuration $(_BuildConfig)
141145
-prepareMachine

eng/restore-internal-tools.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
steps:
2+
- task: NuGetAuthenticate@0
3+
inputs:
4+
nuGetServiceConnections: 'devdiv/dotnet-core-internal-tooling'
5+
forceReinstallCredentialProvider: true
6+
7+
- script: $(Build.SourcesDirectory)\eng\RestoreInternal.cmd
8+
-ci
9+
-projects $(Build.SourcesDirectory)/eng/common/internal/Tools.csproj
10+
/bl:$(Build.SourcesDirectory)/artifacts/log/$(_BuildConfig)/RestoreInternal.binlog
11+
/v:normal
12+
displayName: Restore internal tools
13+
condition: and(succeeded(), ne(variables['_skipRestoreInternalTools'], 'true'))

0 commit comments

Comments
 (0)