1+ # This Yaml Document has been converted by ESAI Yaml Pipeline Conversion Tool.
12parameters :
23
34- name : jobName
@@ -43,9 +44,6 @@ parameters:
4344- name : codeCoverage
4445 type : boolean
4546
46- - name : componentDetection
47- type : boolean
48-
4947- name : sign
5048 type : boolean
5149
@@ -87,15 +85,26 @@ jobs:
8785 DisableDockerDetector : true
8886 nugetMultiFeedWarnLevel : none
8987 CheckoutBranch : ${{ parameters.branch }}
90-
88+ templateContext :
89+ outputs :
90+ - ${{ if or(parameters.unitTests, parameters.functionalTests) }} :
91+ - output : buildArtifacts
92+ displayName : ' Publish Test logs'
93+ condition : always()
94+ PathtoPublish : src/Test/TestLogs
95+ ArtifactName : ${{ parameters.os }}-${{ parameters.arch }}-$(System.JobId)
96+ - ${{ if eq(parameters.publishArtifact, true) }} :
97+ - output : buildArtifacts
98+ displayName : ' Publish Hash Artifact'
99+ PathtoPublish : _package
100+ ArtifactName : agent
101+ - ${{ if eq(parameters.publishArtifact, true) }} :
102+ - output : buildArtifacts
103+ displayName : ' Publish Agent Artifact'
104+ PathtoPublish : _package_hash
105+ ArtifactName : hash
91106 steps :
92107
93- # Component detection
94- - ${{ if parameters.componentDetection }} :
95- - task : ms.vss-governance-buildtask.governance-build-task-component-detection.ComponentGovernanceComponentDetection@0
96- displayName : ' Component Detection'
97-
98- # Clean
99108 - checkout : self
100109 clean : true
101110
@@ -113,7 +122,7 @@ jobs:
113122
114123 # 1ES images used on the ARM pool doesn't contain unzip tool, so we need to install it before starting the build
115124 - ${{ if and(eq(parameters.arch, 'arm64'), ne(parameters.os, 'osx')) }} :
116- - script : sudo apt-get update && sudo apt-get -y install unzip
125+ - script : sudo dnf -y update && sudo dnf -y install unzip
117126 displayName : Install unzip
118127 retryCountOnTaskFailure : 5
119128
@@ -159,9 +168,9 @@ jobs:
159168 - task : UseDotNet@2
160169 displayName : Install .NET Core 6 SDK
161170 inputs :
162- version : ' 6.0.418'
163- packageType : sdk
164- performMultiLevelLookup : true
171+ version : ' 6.0.418'
172+ packageType : sdk
173+ performMultiLevelLookup : true
165174 - script : ${{ variables.devCommand }} testl1 Debug ${{ parameters.os }}-${{ parameters.arch }}
166175 workingDirectory : src
167176 displayName : Functional tests
@@ -176,15 +185,6 @@ jobs:
176185 testRunTitle : ' Agent Tests - ${{ parameters.os }}-${{ parameters.arch }}'
177186 condition : always()
178187
179- # Upload test log
180- 181- displayName : Publish Test logs
182- inputs :
183- pathToPublish : src/Test/TestLogs
184- artifactName : ${{ parameters.os }}-${{ parameters.arch }}-$(System.JobId)
185- artifactType : container
186- condition : always()
187-
188188 # Code coverage
189189 - ${{ if and(parameters.codeCoverage, parameters.unitTests, parameters.functionalTests) }} :
190190 - script : dotnet tool install --global dotnet-reportgenerator-globaltool
@@ -208,7 +208,7 @@ jobs:
208208
209209 - ${{ if parameters.sign }} :
210210 # Signing steps
211- - template : signing.yml
211+ - template : /.azure-pipelines/ signing.yml@self
212212 parameters :
213213 layoutRoot : ${{ variables.layoutRoot }}
214214 isWindows : ${{ eq(parameters.os, 'win') }}
@@ -218,7 +218,7 @@ jobs:
218218
219219 # Package .NET Core Windows dependency (VC++ Redistributable)
220220 - ${{ if eq(parameters.os, 'win') }} :
221- - template : package-vcredist.yml
221+ - template : /.azure-pipelines/ package-vcredist.yml@self
222222 parameters :
223223 layoutRoot : ${{ variables.layoutRoot }}
224224 flavor : ${{ parameters.arch }}
@@ -232,23 +232,6 @@ jobs:
232232 workingDirectory : src
233233 displayName : Hash Package
234234
235- # Upload agent package zip as build artifact
236- 237- displayName : Publish Artifact
238- inputs :
239- pathToPublish : _package
240- artifactName : agent
241- artifactType : container
242-
243- # Publish agent package hash too
244- 245- displayName : Publish Artifact
246- inputs :
247- pathToPublish : _package_hash
248- artifactName : hash
249- artifactType : container
250-
251- # Signing verification
252235 - ${{ if parameters.verifySigning }} :
253236
254237 # Verify all binaries are signed (generate report)
@@ -263,4 +246,4 @@ jobs:
263246 inputs :
264247 CodesignValidation : true
265248 CodesignValidationBreakOn : WarningAbove
266- ToolLogsNotFoundAction : Error
249+ ToolLogsNotFoundAction : Error
0 commit comments