@@ -28,8 +28,74 @@ extends:
2828 sdl :
2929 sourceAnalysisPool : 1ES-PT-Windows-2022
3030 stages :
31+
32+ - stage : DownloadExternalPipelineArtifacts
33+ pool :
34+ name : Azure Pipelines
35+ image : macos-14
36+ os : macOS
37+ jobs :
38+ - job : downloadExternalArtifacts
39+ displayName : DownloadExternalPipelineArtifacts
40+ templateContext :
41+ outputs :
42+ - output : pipelineArtifact
43+ displayName : ' Publish Artifact: framework'
44+ path : ' $(Build.ArtifactStagingDirectory)'
45+ artifactName : external-artifacts
46+ steps :
47+ - checkout : self
48+ fetchTags : false
49+
50+ - task : DownloadPipelineArtifact@2
51+ displayName : ' Download apple artifacts'
52+ inputs :
53+ buildType : ' specific'
54+ project : ' SDK'
55+ pipeline : ' AppCenter-SDK-Apple Build Frameworks and Documentation 1ES'
56+ buildVersionToDownload : ' latestFromBranch'
57+ patterns : ' **/Release/!(*carthage*)*.zip'
58+ targetPath : ' $(Build.SourcesDirectory)/externals/apple_unflattened'
59+
60+ - task : DownloadPipelineArtifact@2
61+ displayName : ' Download android artifacts'
62+ inputs :
63+ buildType : ' specific'
64+ project : ' SDK'
65+ buildVersionToDownload : ' latestFromBranch'
66+ pipeline : ' AppCenter-SDK-Android Publish Maven 1ES'
67+ patterns : ' **/Release/appcenter/**/*.aar'
68+ targetPath : ' $(Build.SourcesDirectory)/externals/android_unflattened'
69+
70+ - task : Bash@3
71+ displayName : ' Flatten Android artifacts'
72+ inputs :
73+ targetType : ' inline'
74+ script : |
75+ echo "Flattening Android artifacts:"
76+ mkdir -p $(Build.SourcesDirectory)/externals/android
77+ find $(Build.SourcesDirectory)/externals/android_unflattened -name '*.aar' -exec mv {} $(Build.SourcesDirectory)/externals/android/ \;
78+ rm -rf $(Build.SourcesDirectory)/externals/android_unflattened
79+
80+ - task : Bash@3
81+ displayName : ' Flatten Apple artifacts'
82+ inputs :
83+ targetType : ' inline'
84+ script : |
85+ echo "Flattening Apple artifacts:"
86+ mkdir -p $(Build.SourcesDirectory)/externals/apple
87+ find $(Build.SourcesDirectory)/externals/apple_unflattened -name '*.zip' -exec mv {} $(Build.SourcesDirectory)/externals/apple/ \;
88+ rm -rf $(Build.SourcesDirectory)/externals/apple_unflattened
89+
90+ - task : CopyFiles@2
91+ displayName : ' Copy artifacts'
92+ inputs :
93+ SourceFolder : ' $(Build.SourcesDirectory)/externals'
94+ TargetFolder : ' $(Build.ArtifactStagingDirectory)'
95+
3196 - stage : BuildWindowsAssemblies
32- dependsOn : []
97+ dependsOn :
98+ - DownloadExternalPipelineArtifacts
3399 jobs :
34100 - job : sdkBuildJob
35101 displayName : BuildWindowsAssemblies
@@ -44,12 +110,11 @@ extends:
44110 - checkout : self
45111 fetchTags : false
46112
47- - task : AzureKeyVault @2
113+ - task : DownloadPipelineArtifact @2
48114 inputs :
49- azureSubscription : ' AC - Dev Infra & Build Pool'
50- KeyVaultName : ' mobile-center-sdk'
51- SecretsFilter : ' appcenter-sdk-blob-storage-access-secret'
52- RunAsPreJob : false
115+ artifact : ' external-artifacts'
116+ targetPath : ' $(Build.SourcesDirectory)/externals'
117+ displayName : ' Download pipeline artifacts'
53118
54119 - task : PowerShell@2
55120 displayName : ' Set Release Version'
@@ -62,21 +127,20 @@ extends:
62127 displayName : ' Prepare Assemblies'
63128 inputs :
64129 target : PrepareAssemblies
65- arguments : ' --StorageAuthParams="$(appcenter-sdk-blob-storage-access-secret)"'
66130 Version : 2.2.0
67131
68-
69132 - task : CopyFiles@2
70133 displayName : ' Copy Assemblies'
71134 inputs :
72135 SourceFolder : ' $(Build.SourcesDirectory)\bin'
73136 TargetFolder : ' $(Build.ArtifactStagingDirectory)'
74137
75138 - stage : BuildDotNetAssemblies
76- dependsOn : []
139+ dependsOn :
140+ - DownloadExternalPipelineArtifacts
77141 pool :
78142 name : Azure Pipelines
79- image : macos-12
143+ image : macos-14
80144 os : macOS
81145 demands :
82146 - msbuild
@@ -92,6 +156,12 @@ extends:
92156 - checkout : self
93157 fetchTags : false
94158
159+ - task : DownloadPipelineArtifact@2
160+ inputs :
161+ artifact : ' external-artifacts'
162+ targetPath : ' $(Build.SourcesDirectory)/externals'
163+ displayName : ' Download pipeline artifacts'
164+
95165 - task : Bash@3
96166 displayName : ' Set Release Version'
97167 inputs :
@@ -106,13 +176,6 @@ extends:
106176 jdkArchitectureOption : x64
107177 jdkSourceOption : PreInstalled
108178
109- - task : AzureKeyVault@2
110- inputs :
111- azureSubscription : ' AC - Dev Infra & Build Pool'
112- KeyVaultName : ' mobile-center-sdk'
113- SecretsFilter : ' appcenter-sdk-blob-storage-access-secret'
114- RunAsPreJob : false
115-
116179 - task : UseDotNet@2
117180 displayName : ' Install .NET SDK'
118181 inputs :
@@ -126,7 +189,6 @@ extends:
126189 displayName : ' Prepare DotNet Assemblies'
127190 inputs :
128191 target : PrepareAssemblies
129- arguments : ' --StorageAuthParams="$(appcenter-sdk-blob-storage-access-secret)"'
130192 Version : 2.2.0
131193
132194 - task : Bash@3
@@ -146,7 +208,7 @@ extends:
146208 displayName : ' Prepare Xamarin Assemblies'
147209 inputs :
148210 target : PrepareAssemblies
149- arguments : ' --MacPlatformId="mac-xamarin" --StorageAuthParams="$(appcenter-sdk-blob-storage-access-secret)" '
211+ arguments : ' --MacPlatformId="mac-xamarin"'
150212 Version : 2.2.0
151213
152214 - task : CopyFiles@2
@@ -223,16 +285,25 @@ extends:
223285 .\scripts\strong-named-sign.cmd "$(Build.ArtifactStagingDirectory)\assemblies" "$(Agent.TempDirectory)\appcenter-pair-key.snk"
224286 displayName: 'Sign assemblies with strong naming'
225287
288+ - task : AzureKeyVault@2
289+ displayName : ' Get MSI Client and Tenant IDs for App Center - Code Signing (PME) Service Connection'
290+ inputs :
291+ azureSubscription : AC - Dev Infra & Build Pool
292+ keyVaultName : mobile-center-sdk
293+ secretsFilter : codesigning-esrp-client-id, codesigning-msi-client-id, codesigning-msi-tenant-id
294+ runAsPreJob : false
295+
226296 - task : EsrpCodeSigning@5
227297 displayName : ' Sign Assemblies'
228298 inputs :
229- ConnectedServiceName : ' App Center - Code Signing (WIF )'
299+ ConnectedServiceName : ' App Center - Code Signing (PME )'
230300 FolderPath : ' $(Build.ArtifactStagingDirectory)\assemblies'
231- AppRegistrationClientId : ' 56ecf8eb-6143-4da0-9a53-716e9c2e6e86'
232- AppRegistrationTenantId : ' 72f988bf-86f1-41af-91ab-2d7cd011db47'
233- AuthAKVName : ' code-signing-poduction'
234- AuthCertName : ' appcenter-codesigning-auth'
235- AuthSignCertName : ' CodeSigning-Certificate-Managed'
301+ UseMSIAuthentication : true
302+ AppRegistrationClientId : $(codesigning-msi-client-id)
303+ AppRegistrationTenantId : $(codesigning-msi-tenant-id)
304+ EsrpClientId : $(codesigning-esrp-client-id)
305+ AuthAKVName : ' ac-code-signing'
306+ AuthSignCertName : ' CodeSigning-Certificate-Managed'
236307 Pattern : ' *.dll,*.winmd'
237308 signConfigType : inlineSignParams
238309 inlineOperation : |
@@ -302,13 +373,6 @@ extends:
302373 env :
303374 AzureServicesAuthConnectionString : ' runAs=App;AppId=$(appcenter-sdk-managed-identity-clientid)'
304375
305- - task : AzureKeyVault@2
306- inputs :
307- azureSubscription : ' AC - Dev Infra & Build Pool'
308- KeyVaultName : ' mobile-center-sdk'
309- SecretsFilter : ' appcenter-sdk-blob-storage-access-secret'
310- RunAsPreJob : false
311-
312376 - task : Cake@2
313377 displayName : ' Pack NuGets'
314378 inputs :
@@ -320,12 +384,13 @@ extends:
320384 displayName : ' Sign Packages'
321385 enabled : true
322386 inputs :
323- ConnectedServiceName : ' App Center - Code Signing (WIF)'
324- AppRegistrationClientId : ' 56ecf8eb-6143-4da0-9a53-716e9c2e6e86'
325- AppRegistrationTenantId : ' 72f988bf-86f1-41af-91ab-2d7cd011db47'
326- AuthAKVName : ' code-signing-poduction'
327- AuthCertName : ' appcenter-codesigning-auth'
328- AuthSignCertName : ' CodeSigning-Certificate-Managed'
387+ ConnectedServiceName : ' App Center - Code Signing (PME)'
388+ UseMSIAuthentication : true
389+ AppRegistrationClientId : $(codesigning-msi-client-id)
390+ AppRegistrationTenantId : $(codesigning-msi-tenant-id)
391+ EsrpClientId : $(codesigning-esrp-client-id)
392+ AuthAKVName : ' ac-code-signing'
393+ AuthSignCertName : ' CodeSigning-Certificate-Managed'
329394 FolderPath : ' $(System.DefaultWorkingDirectory)/'
330395 Pattern : ' Microsoft.AppCenter*.nupkg'
331396 signConfigType : inlineSignParams
0 commit comments