@@ -74,7 +74,7 @@ extends: |
74 | 74 | - name: ob_sdl_tsa_configFile |
75 | 75 | value: $(Build.SourcesDirectory)\PowerShellGet\.config\tsaoptions.json |
76 | 76 | - name: signSrcPath |
77 | | - value: $(repoRoot)/out |
| 77 | + value: $(repoRoot)/out/PowerShellGet |
78 | 78 | - name: ob_sdl_sbom_enabled |
79 | 79 | value: true |
80 | 80 | - name: ob_signing_setup_enabled |
@@ -163,6 +163,10 @@ extends: |
163 | 163 | value: false |
164 | 164 | - name: signOutPath |
165 | 165 | value: $(repoRoot)/signed |
| 166 | + - name: signedModuleRoot |
| 167 | + value: $(signOutPath)/PowerShellGet |
| 168 | + - name: signedNupkgPath |
| 169 | + value: $(signOutPath)/PublishedNupkg |
166 | 170 | - name: ob_signing_setup_enabled |
167 | 171 | value: true |
168 | 172 | # This job is not compiling code, so disable codeQL |
@@ -184,13 +188,13 @@ extends: |
184 | 188 | - task: DownloadPipelineArtifact@2 |
185 | 189 | displayName: 'Download build files' |
186 | 190 | inputs: |
187 | | - targetPath: $(signOutPath) |
| 191 | + targetPath: $(signedModuleRoot) |
188 | 192 | artifact: drop_stagebuild_jobbuild |
189 | 193 |
|
190 | 194 | - pwsh: | |
191 | | - Set-Location "$(signOutPath)" |
192 | | - Write-Host "Contents of signOutPath:" |
193 | | - Get-ChildItem $(signOutPath) -Recurse |
| 195 | + Set-Location "$(signedModuleRoot)" |
| 196 | + Write-Host "Contents of signedModuleRoot:" |
| 197 | + Get-ChildItem $(signedModuleRoot) -Recurse |
194 | 198 | displayName: Capture artifacts directory structure |
195 | 199 |
|
196 | 200 | - pwsh: | |
@@ -201,10 +205,10 @@ extends: |
201 | 205 | displayName: Install PSResourceGet 0.9.0 or above for build.psm1 |
202 | 206 |
|
203 | 207 | - pwsh: | |
204 | | - Set-Location "$(signOutPath)\PowerShellGet" |
205 | | - New-Item -ItemType Directory -Path "$(signOutPath)\PublishedNupkg" -Force |
206 | | - Register-PSResourceRepository -Name 'localRepo' -Uri "$(signOutPath)\PublishedNupkg" |
207 | | - Publish-PSResource -Path "$(signOutPath)\PowerShellGet" -Repository 'localRepo' -Verbose |
| 208 | + Set-Location "$(signOutPath)" |
| 209 | + New-Item -ItemType Directory -Path "$(signedNupkgPath)" -Force |
| 210 | + Register-PSResourceRepository -Name 'localRepo' -Uri "$(signedNupkgPath)" |
| 211 | + Publish-PSResource -Path "$(signedModuleRoot)" -Repository 'localRepo' -Verbose |
208 | 212 | displayName: Create nupkg for publishing |
209 | 213 |
|
210 | 214 | - task: onebranch.pipeline.signing@1 |
@@ -213,18 +217,18 @@ extends: |
213 | 217 | command: 'sign' |
214 | 218 | signing_profile: external_distribution |
215 | 219 | files_to_sign: '**\*.nupkg' |
216 | | - search_root: "$(signOutPath)\PublishedNupkg" |
| 220 | + search_root: "$(signedNupkgPath)" |
217 | 221 |
|
218 | 222 | - pwsh: | |
219 | | - Set-Location "$(signOutPath)\PublishedNupkg" |
220 | | - Write-Host "Contents of signOutPath:" |
221 | | - Get-ChildItem "$(signOutPath)" -Recurse |
| 223 | + Set-Location "$(signedNupkgPath)" |
| 224 | + Write-Host "Contents of signedNupkgPath:" |
| 225 | + Get-ChildItem "$(signedNupkgPath)" -Recurse |
222 | 226 | displayName: Find Nupkg |
223 | 227 |
|
224 | 228 | - task: CopyFiles@2 |
225 | 229 | displayName: "Copy nupkg to ob_outputDirectory - '$(ob_outputDirectory)'" |
226 | 230 | inputs: |
227 | | - Contents: $(signOutPath)\PublishedNupkg\PowerShellGet.*.nupkg |
| 231 | + Contents: $(signedNupkgPath)\PowerShellGet.*.nupkg |
228 | 232 | TargetFolder: $(ob_outputDirectory) |
229 | 233 |
|
230 | 234 | - pwsh: | |
|