From d27f0a5597bbad652028f587311deecd17f765d7 Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" Date: Sat, 22 Jun 2024 12:58:31 +0000 Subject: [PATCH 01/11] Update dependencies from https://github.com/dotnet/arcade build 20240621.3 Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.Helix.Sdk , Microsoft.DotNet.SignTool , Microsoft.DotNet.XUnitExtensions From Version 8.0.0-beta.24311.3 -> To Version 8.0.0-beta.24321.3 --- NuGet.config | 1 + eng/Version.Details.xml | 16 +++---- eng/Versions.props | 4 +- .../templates-official/job/source-build.yml | 8 ++++ .../templates-official/jobs/source-build.yml | 8 ++++ .../steps/enable-internal-runtimes.yml | 28 ++++++++++++ .../steps/get-delegation-sas.yml | 43 +++++++++++++++++++ .../steps/get-federated-access-token.yml | 28 ++++++++++++ eng/common/templates/job/source-build.yml | 8 ++++ eng/common/templates/jobs/source-build.yml | 8 ++++ .../steps/enable-internal-runtimes.yml | 28 ++++++++++++ .../templates/steps/get-delegation-sas.yml | 43 +++++++++++++++++++ .../steps/get-federated-access-token.yml | 28 ++++++++++++ global.json | 4 +- 14 files changed, 243 insertions(+), 12 deletions(-) create mode 100644 eng/common/templates-official/steps/enable-internal-runtimes.yml create mode 100644 eng/common/templates-official/steps/get-delegation-sas.yml create mode 100644 eng/common/templates-official/steps/get-federated-access-token.yml create mode 100644 eng/common/templates/steps/enable-internal-runtimes.yml create mode 100644 eng/common/templates/steps/get-delegation-sas.yml create mode 100644 eng/common/templates/steps/get-federated-access-token.yml diff --git a/NuGet.config b/NuGet.config index ca1f5e248d72..2fe66c7b93ed 100644 --- a/NuGet.config +++ b/NuGet.config @@ -24,6 +24,7 @@ + diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index 206c729e37e1..c5d071ecc34c 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -483,22 +483,22 @@ - + https://github.com/dotnet/arcade - c214b6ad17aedca4fa48294d80f6c52ef2463081 + a95bcc256e9bdf47394e4dab04872811c16daaea - + https://github.com/dotnet/arcade - c214b6ad17aedca4fa48294d80f6c52ef2463081 + a95bcc256e9bdf47394e4dab04872811c16daaea - + https://github.com/dotnet/arcade - c214b6ad17aedca4fa48294d80f6c52ef2463081 + a95bcc256e9bdf47394e4dab04872811c16daaea - + https://github.com/dotnet/arcade - c214b6ad17aedca4fa48294d80f6c52ef2463081 + a95bcc256e9bdf47394e4dab04872811c16daaea https://dev.azure.com/dnceng/internal/_git/dotnet-runtime diff --git a/eng/Versions.props b/eng/Versions.props index 734ba59756cd..e20ee169fdfc 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -35,7 +35,7 @@ 7.0.0 4.0.0 7.0.0 - 8.0.0-beta.24311.3 + 8.0.0-beta.24321.3 7.0.0-preview.22423.2 8.0.0 4.3.0 @@ -210,7 +210,7 @@ 6.12.0 6.1.0 - 8.0.0-beta.24311.3 + 8.0.0-beta.24321.3 4.18.4 1.3.2 8.0.0-beta.23607.1 diff --git a/eng/common/templates-official/job/source-build.yml b/eng/common/templates-official/job/source-build.yml index f193dfbe2366..f983033bb028 100644 --- a/eng/common/templates-official/job/source-build.yml +++ b/eng/common/templates-official/job/source-build.yml @@ -31,6 +31,12 @@ parameters: # container and pool. platform: {} + # If set to true and running on a non-public project, + # Internal blob storage locations will be enabled. + # This is not enabled by default because many repositories do not need internal sources + # and do not need to have the required service connections approved in the pipeline. + enableInternalSources: false + jobs: - job: ${{ parameters.jobNamePrefix }}_${{ parameters.platform.name }} displayName: Source-Build (${{ parameters.platform.name }}) @@ -62,6 +68,8 @@ jobs: clean: all steps: + - ${{ if eq(parameters.enableInternalSources, true) }}: + - template: /eng/common/templates-official/steps/enable-internal-runtimes.yml - template: /eng/common/templates-official/steps/source-build.yml parameters: platform: ${{ parameters.platform }} diff --git a/eng/common/templates-official/jobs/source-build.yml b/eng/common/templates-official/jobs/source-build.yml index 08e5db9bb116..5cf6a269c0b6 100644 --- a/eng/common/templates-official/jobs/source-build.yml +++ b/eng/common/templates-official/jobs/source-build.yml @@ -21,6 +21,12 @@ parameters: # one job runs on 'defaultManagedPlatform'. platforms: [] + # If set to true and running on a non-public project, + # Internal nuget and blob storage locations will be enabled. + # This is not enabled by default because many repositories do not need internal sources + # and do not need to have the required service connections approved in the pipeline. + enableInternalSources: false + jobs: - ${{ if ne(parameters.allCompletedJobId, '') }}: @@ -38,9 +44,11 @@ jobs: parameters: jobNamePrefix: ${{ parameters.jobNamePrefix }} platform: ${{ platform }} + enableInternalSources: ${{ parameters.enableInternalSources }} - ${{ if eq(length(parameters.platforms), 0) }}: - template: /eng/common/templates-official/job/source-build.yml parameters: jobNamePrefix: ${{ parameters.jobNamePrefix }} platform: ${{ parameters.defaultManagedPlatform }} + enableInternalSources: ${{ parameters.enableInternalSources }} diff --git a/eng/common/templates-official/steps/enable-internal-runtimes.yml b/eng/common/templates-official/steps/enable-internal-runtimes.yml new file mode 100644 index 000000000000..93a8394a666b --- /dev/null +++ b/eng/common/templates-official/steps/enable-internal-runtimes.yml @@ -0,0 +1,28 @@ +# Obtains internal runtime download credentials and populates the 'dotnetbuilds-internal-container-read-token-base64' +# variable with the base64-encoded SAS token, by default + +parameters: +- name: federatedServiceConnection + type: string + default: 'dotnetbuilds-internal-read' +- name: outputVariableName + type: string + default: 'dotnetbuilds-internal-container-read-token-base64' +- name: expiryInHours + type: number + default: 1 +- name: base64Encode + type: boolean + default: true + +steps: +- ${{ if ne(variables['System.TeamProject'], 'public') }}: + - template: /eng/common/templates-official/steps/get-delegation-sas.yml + parameters: + federatedServiceConnection: ${{ parameters.federatedServiceConnection }} + outputVariableName: ${{ parameters.outputVariableName }} + expiryInHours: ${{ parameters.expiryInHours }} + base64Encode: ${{ parameters.base64Encode }} + storageAccount: dotnetbuilds + container: internal + permissions: rl diff --git a/eng/common/templates-official/steps/get-delegation-sas.yml b/eng/common/templates-official/steps/get-delegation-sas.yml new file mode 100644 index 000000000000..c0e8f91317f0 --- /dev/null +++ b/eng/common/templates-official/steps/get-delegation-sas.yml @@ -0,0 +1,43 @@ +parameters: +- name: federatedServiceConnection + type: string +- name: outputVariableName + type: string +- name: expiryInHours + type: number + default: 1 +- name: base64Encode + type: boolean + default: false +- name: storageAccount + type: string +- name: container + type: string +- name: permissions + type: string + default: 'rl' + +steps: +- task: AzureCLI@2 + displayName: 'Generate delegation SAS Token for ${{ parameters.storageAccount }}/${{ parameters.container }}' + inputs: + azureSubscription: ${{ parameters.federatedServiceConnection }} + scriptType: 'pscore' + scriptLocation: 'inlineScript' + inlineScript: | + # Calculate the expiration of the SAS token and convert to UTC + $expiry = (Get-Date).AddHours(${{ parameters.expiryInHours }}).ToUniversalTime().ToString("yyyy-MM-ddTHH:mm:ssZ") + + $sas = az storage container generate-sas --account-name ${{ parameters.storageAccount }} --name ${{ parameters.container }} --permissions ${{ parameters.permissions }} --expiry $expiry --auth-mode login --as-user -o tsv + + if ($LASTEXITCODE -ne 0) { + Write-Error "Failed to generate SAS token." + exit 1 + } + + if ('${{ parameters.base64Encode }}' -eq 'true') { + $sas = [Convert]::ToBase64String([System.Text.Encoding]::UTF8.GetBytes($sas)) + } + + Write-Host "Setting '${{ parameters.outputVariableName }}' with the access token value" + Write-Host "##vso[task.setvariable variable=${{ parameters.outputVariableName }};issecret=true]$sas" diff --git a/eng/common/templates-official/steps/get-federated-access-token.yml b/eng/common/templates-official/steps/get-federated-access-token.yml new file mode 100644 index 000000000000..e3786cef6dfd --- /dev/null +++ b/eng/common/templates-official/steps/get-federated-access-token.yml @@ -0,0 +1,28 @@ +parameters: +- name: federatedServiceConnection + type: string +- name: outputVariableName + type: string +# Resource to get a token for. Common values include: +# - '499b84ac-1321-427f-aa17-267ca6975798' for Azure DevOps +# - 'https://storage.azure.com/' for storage +# Defaults to Azure DevOps +- name: resource + type: string + default: '499b84ac-1321-427f-aa17-267ca6975798' + +steps: +- task: AzureCLI@2 + displayName: 'Getting federated access token for feeds' + inputs: + azureSubscription: ${{ parameters.federatedServiceConnection }} + scriptType: 'pscore' + scriptLocation: 'inlineScript' + inlineScript: | + $accessToken = az account get-access-token --query accessToken --resource ${{ parameters.resource }} --output tsv + if ($LASTEXITCODE -ne 0) { + Write-Error "Failed to get access token for resource '${{ parameters.resource }}'" + exit 1 + } + Write-Host "Setting '${{ parameters.outputVariableName }}' with the access token value" + Write-Host "##vso[task.setvariable variable=${{ parameters.outputVariableName }};issecret=true]$accessToken" diff --git a/eng/common/templates/job/source-build.yml b/eng/common/templates/job/source-build.yml index 8a3deef2b727..c0ff472b697b 100644 --- a/eng/common/templates/job/source-build.yml +++ b/eng/common/templates/job/source-build.yml @@ -31,6 +31,12 @@ parameters: # container and pool. platform: {} + # If set to true and running on a non-public project, + # Internal blob storage locations will be enabled. + # This is not enabled by default because many repositories do not need internal sources + # and do not need to have the required service connections approved in the pipeline. + enableInternalSources: false + jobs: - job: ${{ parameters.jobNamePrefix }}_${{ parameters.platform.name }} displayName: Source-Build (${{ parameters.platform.name }}) @@ -61,6 +67,8 @@ jobs: clean: all steps: + - ${{ if eq(parameters.enableInternalSources, true) }}: + - template: /eng/common/templates/steps/enable-internal-runtimes.yml - template: /eng/common/templates/steps/source-build.yml parameters: platform: ${{ parameters.platform }} diff --git a/eng/common/templates/jobs/source-build.yml b/eng/common/templates/jobs/source-build.yml index a15b07eb51d9..5f46bfa895c1 100644 --- a/eng/common/templates/jobs/source-build.yml +++ b/eng/common/templates/jobs/source-build.yml @@ -21,6 +21,12 @@ parameters: # one job runs on 'defaultManagedPlatform'. platforms: [] + # If set to true and running on a non-public project, + # Internal nuget and blob storage locations will be enabled. + # This is not enabled by default because many repositories do not need internal sources + # and do not need to have the required service connections approved in the pipeline. + enableInternalSources: false + jobs: - ${{ if ne(parameters.allCompletedJobId, '') }}: @@ -38,9 +44,11 @@ jobs: parameters: jobNamePrefix: ${{ parameters.jobNamePrefix }} platform: ${{ platform }} + enableInternalSources: ${{ parameters.enableInternalSources }} - ${{ if eq(length(parameters.platforms), 0) }}: - template: /eng/common/templates/job/source-build.yml parameters: jobNamePrefix: ${{ parameters.jobNamePrefix }} platform: ${{ parameters.defaultManagedPlatform }} + enableInternalSources: ${{ parameters.enableInternalSources }} diff --git a/eng/common/templates/steps/enable-internal-runtimes.yml b/eng/common/templates/steps/enable-internal-runtimes.yml new file mode 100644 index 000000000000..54dc9416c519 --- /dev/null +++ b/eng/common/templates/steps/enable-internal-runtimes.yml @@ -0,0 +1,28 @@ +# Obtains internal runtime download credentials and populates the 'dotnetbuilds-internal-container-read-token-base64' +# variable with the base64-encoded SAS token, by default + +parameters: +- name: federatedServiceConnection + type: string + default: 'dotnetbuilds-internal-read' +- name: outputVariableName + type: string + default: 'dotnetbuilds-internal-container-read-token-base64' +- name: expiryInHours + type: number + default: 1 +- name: base64Encode + type: boolean + default: true + +steps: +- ${{ if ne(variables['System.TeamProject'], 'public') }}: + - template: /eng/common/templates/steps/get-delegation-sas.yml + parameters: + federatedServiceConnection: ${{ parameters.federatedServiceConnection }} + outputVariableName: ${{ parameters.outputVariableName }} + expiryInHours: ${{ parameters.expiryInHours }} + base64Encode: ${{ parameters.base64Encode }} + storageAccount: dotnetbuilds + container: internal + permissions: rl diff --git a/eng/common/templates/steps/get-delegation-sas.yml b/eng/common/templates/steps/get-delegation-sas.yml new file mode 100644 index 000000000000..c0e8f91317f0 --- /dev/null +++ b/eng/common/templates/steps/get-delegation-sas.yml @@ -0,0 +1,43 @@ +parameters: +- name: federatedServiceConnection + type: string +- name: outputVariableName + type: string +- name: expiryInHours + type: number + default: 1 +- name: base64Encode + type: boolean + default: false +- name: storageAccount + type: string +- name: container + type: string +- name: permissions + type: string + default: 'rl' + +steps: +- task: AzureCLI@2 + displayName: 'Generate delegation SAS Token for ${{ parameters.storageAccount }}/${{ parameters.container }}' + inputs: + azureSubscription: ${{ parameters.federatedServiceConnection }} + scriptType: 'pscore' + scriptLocation: 'inlineScript' + inlineScript: | + # Calculate the expiration of the SAS token and convert to UTC + $expiry = (Get-Date).AddHours(${{ parameters.expiryInHours }}).ToUniversalTime().ToString("yyyy-MM-ddTHH:mm:ssZ") + + $sas = az storage container generate-sas --account-name ${{ parameters.storageAccount }} --name ${{ parameters.container }} --permissions ${{ parameters.permissions }} --expiry $expiry --auth-mode login --as-user -o tsv + + if ($LASTEXITCODE -ne 0) { + Write-Error "Failed to generate SAS token." + exit 1 + } + + if ('${{ parameters.base64Encode }}' -eq 'true') { + $sas = [Convert]::ToBase64String([System.Text.Encoding]::UTF8.GetBytes($sas)) + } + + Write-Host "Setting '${{ parameters.outputVariableName }}' with the access token value" + Write-Host "##vso[task.setvariable variable=${{ parameters.outputVariableName }};issecret=true]$sas" diff --git a/eng/common/templates/steps/get-federated-access-token.yml b/eng/common/templates/steps/get-federated-access-token.yml new file mode 100644 index 000000000000..c8c49cc0e8f0 --- /dev/null +++ b/eng/common/templates/steps/get-federated-access-token.yml @@ -0,0 +1,28 @@ +parameters: +- name: federatedServiceConnection + type: string +- name: outputVariableName + type: string +# Resource to get a token for. Common values include: +# - '499b84ac-1321-427f-aa17-267ca6975798' for Azure DevOps +# - 'https://storage.azure.com/' for storage +# Defaults to Azure DevOps +- name: resource + type: string + default: '499b84ac-1321-427f-aa17-267ca6975798' + +steps: +- task: AzureCLI@2 + displayName: 'Getting federated access token for feeds' + inputs: + azureSubscription: ${{ parameters.federatedServiceConnection }} + scriptType: 'pscore' + scriptLocation: 'inlineScript' + inlineScript: | + $accessToken = az account get-access-token --query accessToken --resource ${{ parameters.resource }} --output tsv + if ($LASTEXITCODE -ne 0) { + Write-Error "Failed to get access token for resource '${{ parameters.resource }}'" + exit 1 + } + Write-Host "Setting '${{ parameters.outputVariableName }}' with the access token value" + Write-Host "##vso[task.setvariable variable=${{ parameters.outputVariableName }};issecret=true]$accessToken" \ No newline at end of file diff --git a/global.json b/global.json index d2af4d682074..2d6984391166 100644 --- a/global.json +++ b/global.json @@ -14,7 +14,7 @@ } }, "msbuild-sdks": { - "Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.24311.3", - "Microsoft.DotNet.Helix.Sdk": "8.0.0-beta.24311.3" + "Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.24321.3", + "Microsoft.DotNet.Helix.Sdk": "8.0.0-beta.24321.3" } } From cc0c678d19bff28ae2001f235dba912bbaa51009 Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" Date: Sun, 23 Jun 2024 12:50:16 +0000 Subject: [PATCH 02/11] Update dependencies from https://github.com/dotnet/arcade build 20240621.3 Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.Helix.Sdk , Microsoft.DotNet.SignTool , Microsoft.DotNet.XUnitExtensions From Version 8.0.0-beta.24311.3 -> To Version 8.0.0-beta.24321.3 From b48ab67e6a6f3a741e3f8270da454e00d5d7a886 Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" Date: Mon, 24 Jun 2024 12:42:56 +0000 Subject: [PATCH 03/11] Update dependencies from https://github.com/dotnet/arcade build 20240624.1 Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.Helix.Sdk , Microsoft.DotNet.SignTool , Microsoft.DotNet.XUnitExtensions From Version 8.0.0-beta.24311.3 -> To Version 8.0.0-beta.24324.1 --- eng/Version.Details.xml | 16 ++++++++-------- eng/Versions.props | 4 ++-- global.json | 4 ++-- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index c5d071ecc34c..66bc53a272a4 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -483,22 +483,22 @@ - + https://github.com/dotnet/arcade - a95bcc256e9bdf47394e4dab04872811c16daaea + 748cd976bf8b0f69b809e569943635ab8be36dc8 - + https://github.com/dotnet/arcade - a95bcc256e9bdf47394e4dab04872811c16daaea + 748cd976bf8b0f69b809e569943635ab8be36dc8 - + https://github.com/dotnet/arcade - a95bcc256e9bdf47394e4dab04872811c16daaea + 748cd976bf8b0f69b809e569943635ab8be36dc8 - + https://github.com/dotnet/arcade - a95bcc256e9bdf47394e4dab04872811c16daaea + 748cd976bf8b0f69b809e569943635ab8be36dc8 https://dev.azure.com/dnceng/internal/_git/dotnet-runtime diff --git a/eng/Versions.props b/eng/Versions.props index e20ee169fdfc..20d93236329c 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -35,7 +35,7 @@ 7.0.0 4.0.0 7.0.0 - 8.0.0-beta.24321.3 + 8.0.0-beta.24324.1 7.0.0-preview.22423.2 8.0.0 4.3.0 @@ -210,7 +210,7 @@ 6.12.0 6.1.0 - 8.0.0-beta.24321.3 + 8.0.0-beta.24324.1 4.18.4 1.3.2 8.0.0-beta.23607.1 diff --git a/global.json b/global.json index 2d6984391166..18a15064de9d 100644 --- a/global.json +++ b/global.json @@ -14,7 +14,7 @@ } }, "msbuild-sdks": { - "Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.24321.3", - "Microsoft.DotNet.Helix.Sdk": "8.0.0-beta.24321.3" + "Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.24324.1", + "Microsoft.DotNet.Helix.Sdk": "8.0.0-beta.24324.1" } } From f024a06f8f6e88ec813418248d0c0138c057631f Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" Date: Tue, 25 Jun 2024 12:57:28 +0000 Subject: [PATCH 04/11] Update dependencies from https://github.com/dotnet/arcade build 20240624.7 Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.Helix.Sdk , Microsoft.DotNet.SignTool , Microsoft.DotNet.XUnitExtensions From Version 8.0.0-beta.24311.3 -> To Version 8.0.0-beta.24324.7 --- NuGet.config | 2 ++ eng/Version.Details.xml | 16 +++++------ eng/Versions.props | 4 +-- eng/common/post-build/publish-using-darc.ps1 | 15 +++++----- .../job/publish-build-assets.yml | 12 ++++---- .../post-build/post-build.yml | 8 ++++-- .../templates/job/publish-build-assets.yml | 12 ++++---- .../templates/post-build/post-build.yml | 8 ++++-- .../post-build/setup-maestro-vars.yml | 28 +++++++++---------- global.json | 4 +-- 10 files changed, 59 insertions(+), 50 deletions(-) diff --git a/NuGet.config b/NuGet.config index 2fe66c7b93ed..dc29aad8cfa6 100644 --- a/NuGet.config +++ b/NuGet.config @@ -24,6 +24,8 @@ + + diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index 66bc53a272a4..f5b905a2d433 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -483,22 +483,22 @@ - + https://github.com/dotnet/arcade - 748cd976bf8b0f69b809e569943635ab8be36dc8 + 3fe41d9e97519a4e9b48293906dbf58714ea9a0d - + https://github.com/dotnet/arcade - 748cd976bf8b0f69b809e569943635ab8be36dc8 + 3fe41d9e97519a4e9b48293906dbf58714ea9a0d - + https://github.com/dotnet/arcade - 748cd976bf8b0f69b809e569943635ab8be36dc8 + 3fe41d9e97519a4e9b48293906dbf58714ea9a0d - + https://github.com/dotnet/arcade - 748cd976bf8b0f69b809e569943635ab8be36dc8 + 3fe41d9e97519a4e9b48293906dbf58714ea9a0d https://dev.azure.com/dnceng/internal/_git/dotnet-runtime diff --git a/eng/Versions.props b/eng/Versions.props index 20d93236329c..3d33c3270349 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -35,7 +35,7 @@ 7.0.0 4.0.0 7.0.0 - 8.0.0-beta.24324.1 + 8.0.0-beta.24324.7 7.0.0-preview.22423.2 8.0.0 4.3.0 @@ -210,7 +210,7 @@ 6.12.0 6.1.0 - 8.0.0-beta.24324.1 + 8.0.0-beta.24324.7 4.18.4 1.3.2 8.0.0-beta.23607.1 diff --git a/eng/common/post-build/publish-using-darc.ps1 b/eng/common/post-build/publish-using-darc.ps1 index 5a3a32ea8d75..238945cb5ab4 100644 --- a/eng/common/post-build/publish-using-darc.ps1 +++ b/eng/common/post-build/publish-using-darc.ps1 @@ -2,7 +2,6 @@ param( [Parameter(Mandatory=$true)][int] $BuildId, [Parameter(Mandatory=$true)][int] $PublishingInfraVersion, [Parameter(Mandatory=$true)][string] $AzdoToken, - [Parameter(Mandatory=$true)][string] $MaestroToken, [Parameter(Mandatory=$false)][string] $MaestroApiEndPoint = 'https://maestro.dot.net', [Parameter(Mandatory=$true)][string] $WaitPublishingFinish, [Parameter(Mandatory=$false)][string] $ArtifactsPublishingAdditionalParameters, @@ -31,13 +30,13 @@ try { } & $darc add-build-to-channel ` - --id $buildId ` - --publishing-infra-version $PublishingInfraVersion ` - --default-channels ` - --source-branch main ` - --azdev-pat $AzdoToken ` - --bar-uri $MaestroApiEndPoint ` - --password $MaestroToken ` + --id $buildId ` + --publishing-infra-version $PublishingInfraVersion ` + --default-channels ` + --source-branch main ` + --azdev-pat "$AzdoToken" ` + --bar-uri "$MaestroApiEndPoint" ` + --ci ` @optionalParams if ($LastExitCode -ne 0) { diff --git a/eng/common/templates-official/job/publish-build-assets.yml b/eng/common/templates-official/job/publish-build-assets.yml index 589ac80a18b7..d01739c12857 100644 --- a/eng/common/templates-official/job/publish-build-assets.yml +++ b/eng/common/templates-official/job/publish-build-assets.yml @@ -76,13 +76,16 @@ jobs: - task: NuGetAuthenticate@1 - - task: PowerShell@2 + - task: AzureCLI@2 displayName: Publish Build Assets inputs: - filePath: eng\common\sdk-task.ps1 - arguments: -task PublishBuildAssets -restore -msbuildEngine dotnet + azureSubscription: "Darc: Maestro Production" + scriptType: ps + scriptLocation: scriptPath + scriptPath: $(Build.SourcesDirectory)/eng/common/sdk-task.ps1 + arguments: > + -task PublishBuildAssets -restore -msbuildEngine dotnet /p:ManifestsPath='$(Build.StagingDirectory)/Download/AssetManifests' - /p:BuildAssetRegistryToken=$(MaestroAccessToken) /p:MaestroApiEndpoint=https://maestro-prod.westus2.cloudapp.azure.com /p:PublishUsingPipelines=${{ parameters.publishUsingPipelines }} /p:OfficialBuildId=$(Build.BuildNumber) @@ -144,7 +147,6 @@ jobs: arguments: -BuildId $(BARBuildId) -PublishingInfraVersion 3 -AzdoToken '$(publishing-dnceng-devdiv-code-r-build-re)' - -MaestroToken '$(MaestroApiAccessToken)' -WaitPublishingFinish true -ArtifactsPublishingAdditionalParameters '${{ parameters.artifactsPublishingAdditionalParameters }}' -SymbolPublishingAdditionalParameters '${{ parameters.symbolPublishingAdditionalParameters }}' diff --git a/eng/common/templates-official/post-build/post-build.yml b/eng/common/templates-official/post-build/post-build.yml index da1f40958b45..0dfa387e7b78 100644 --- a/eng/common/templates-official/post-build/post-build.yml +++ b/eng/common/templates-official/post-build/post-build.yml @@ -272,14 +272,16 @@ stages: - task: NuGetAuthenticate@1 - - task: PowerShell@2 + - task: AzureCLI@2 displayName: Publish Using Darc inputs: - filePath: $(Build.SourcesDirectory)/eng/common/post-build/publish-using-darc.ps1 + azureSubscription: "Darc: Maestro Production" + scriptType: ps + scriptLocation: scriptPath + scriptPath: $(Build.SourcesDirectory)/eng/common/post-build/publish-using-darc.ps1 arguments: -BuildId $(BARBuildId) -PublishingInfraVersion ${{ parameters.publishingInfraVersion }} -AzdoToken '$(publishing-dnceng-devdiv-code-r-build-re)' - -MaestroToken '$(MaestroApiAccessToken)' -WaitPublishingFinish true -ArtifactsPublishingAdditionalParameters '${{ parameters.artifactsPublishingAdditionalParameters }}' -SymbolPublishingAdditionalParameters '${{ parameters.symbolPublishingAdditionalParameters }}' diff --git a/eng/common/templates/job/publish-build-assets.yml b/eng/common/templates/job/publish-build-assets.yml index 8ec0151def21..9fd69fa7c9b7 100644 --- a/eng/common/templates/job/publish-build-assets.yml +++ b/eng/common/templates/job/publish-build-assets.yml @@ -74,13 +74,16 @@ jobs: - task: NuGetAuthenticate@1 - - task: PowerShell@2 + - task: AzureCLI@2 displayName: Publish Build Assets inputs: - filePath: eng\common\sdk-task.ps1 - arguments: -task PublishBuildAssets -restore -msbuildEngine dotnet + azureSubscription: "Darc: Maestro Production" + scriptType: ps + scriptLocation: scriptPath + scriptPath: $(Build.SourcesDirectory)/eng/common/sdk-task.ps1 + arguments: > + -task PublishBuildAssets -restore -msbuildEngine dotnet /p:ManifestsPath='$(Build.StagingDirectory)/Download/AssetManifests' - /p:BuildAssetRegistryToken=$(MaestroAccessToken) /p:MaestroApiEndpoint=https://maestro.dot.net /p:PublishUsingPipelines=${{ parameters.publishUsingPipelines }} /p:OfficialBuildId=$(Build.BuildNumber) @@ -140,7 +143,6 @@ jobs: arguments: -BuildId $(BARBuildId) -PublishingInfraVersion 3 -AzdoToken '$(publishing-dnceng-devdiv-code-r-build-re)' - -MaestroToken '$(MaestroApiAccessToken)' -WaitPublishingFinish true -ArtifactsPublishingAdditionalParameters '${{ parameters.artifactsPublishingAdditionalParameters }}' -SymbolPublishingAdditionalParameters '${{ parameters.symbolPublishingAdditionalParameters }}' diff --git a/eng/common/templates/post-build/post-build.yml b/eng/common/templates/post-build/post-build.yml index aba44a25a338..2db4933468fd 100644 --- a/eng/common/templates/post-build/post-build.yml +++ b/eng/common/templates/post-build/post-build.yml @@ -268,14 +268,16 @@ stages: - task: NuGetAuthenticate@1 - - task: PowerShell@2 + - task: AzureCLI@2 displayName: Publish Using Darc inputs: - filePath: $(Build.SourcesDirectory)/eng/common/post-build/publish-using-darc.ps1 + azureSubscription: "Darc: Maestro Production" + scriptType: ps + scriptLocation: scriptPath + scriptPath: $(Build.SourcesDirectory)/eng/common/post-build/publish-using-darc.ps1 arguments: -BuildId $(BARBuildId) -PublishingInfraVersion ${{ parameters.publishingInfraVersion }} -AzdoToken '$(publishing-dnceng-devdiv-code-r-build-re)' - -MaestroToken '$(MaestroApiAccessToken)' -WaitPublishingFinish true -ArtifactsPublishingAdditionalParameters '${{ parameters.artifactsPublishingAdditionalParameters }}' -SymbolPublishingAdditionalParameters '${{ parameters.symbolPublishingAdditionalParameters }}' diff --git a/eng/common/templates/post-build/setup-maestro-vars.yml b/eng/common/templates/post-build/setup-maestro-vars.yml index 0c87f149a4ad..64b9abc68504 100644 --- a/eng/common/templates/post-build/setup-maestro-vars.yml +++ b/eng/common/templates/post-build/setup-maestro-vars.yml @@ -11,13 +11,14 @@ steps: artifactName: ReleaseConfigs checkDownloadedFiles: true - - task: PowerShell@2 + - task: AzureCLI@2 name: setReleaseVars displayName: Set Release Configs Vars inputs: - targetType: inline - pwsh: true - script: | + azureSubscription: "Darc: Maestro Production" + scriptType: pscore + scriptLocation: inlineScript + inlineScript: | try { if (!$Env:PromoteToMaestroChannels -or $Env:PromoteToMaestroChannels.Trim() -eq '') { $Content = Get-Content $(Build.StagingDirectory)/ReleaseConfigs/ReleaseConfigs.txt @@ -31,15 +32,16 @@ steps: $AzureDevOpsBuildId = $Env:Build_BuildId } else { - $buildApiEndpoint = "${Env:MaestroApiEndPoint}/api/builds/${Env:BARBuildId}?api-version=${Env:MaestroApiVersion}" + . $(Build.SourcesDirectory)\eng\common\tools.ps1 + $darc = Get-Darc + $buildInfo = & $darc get-build ` + --id ${{ parameters.BARBuildId }} ` + --extended ` + --output-format json ` + --ci ` + | convertFrom-Json - $apiHeaders = New-Object 'System.Collections.Generic.Dictionary[[String],[String]]' - $apiHeaders.Add('Accept', 'application/json') - $apiHeaders.Add('Authorization',"Bearer ${Env:MAESTRO_API_TOKEN}") - - $buildInfo = try { Invoke-WebRequest -Method Get -Uri $buildApiEndpoint -Headers $apiHeaders | ConvertFrom-Json } catch { Write-Host "Error: $_" } - - $BarId = $Env:BARBuildId + $BarId = ${{ parameters.BARBuildId }} $Channels = $Env:PromoteToMaestroChannels -split "," $Channels = $Channels -join "][" $Channels = "[$Channels]" @@ -65,6 +67,4 @@ steps: exit 1 } env: - MAESTRO_API_TOKEN: $(MaestroApiAccessToken) - BARBuildId: ${{ parameters.BARBuildId }} PromoteToMaestroChannels: ${{ parameters.PromoteToChannelIds }} diff --git a/global.json b/global.json index 18a15064de9d..3299cf13efbd 100644 --- a/global.json +++ b/global.json @@ -14,7 +14,7 @@ } }, "msbuild-sdks": { - "Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.24324.1", - "Microsoft.DotNet.Helix.Sdk": "8.0.0-beta.24324.1" + "Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.24324.7", + "Microsoft.DotNet.Helix.Sdk": "8.0.0-beta.24324.7" } } From e12c6f06f82c0ff1c7175dac07c17a9229668812 Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" Date: Wed, 26 Jun 2024 12:55:07 +0000 Subject: [PATCH 05/11] Update dependencies from https://github.com/dotnet/arcade build 20240624.7 Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.Helix.Sdk , Microsoft.DotNet.SignTool , Microsoft.DotNet.XUnitExtensions From Version 8.0.0-beta.24311.3 -> To Version 8.0.0-beta.24324.7 From 9a16d862433533c1011ad81ccf52d6dc49041141 Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" Date: Thu, 27 Jun 2024 13:04:18 +0000 Subject: [PATCH 06/11] Update dependencies from https://github.com/dotnet/arcade build 20240624.7 Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.Helix.Sdk , Microsoft.DotNet.SignTool , Microsoft.DotNet.XUnitExtensions From Version 8.0.0-beta.24311.3 -> To Version 8.0.0-beta.24324.7 --- NuGet.config | 1 + 1 file changed, 1 insertion(+) diff --git a/NuGet.config b/NuGet.config index dc29aad8cfa6..600ebd405c65 100644 --- a/NuGet.config +++ b/NuGet.config @@ -24,6 +24,7 @@ + From 149565b7f5c0b3995365222070abdcb8e9a1cf16 Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" Date: Fri, 28 Jun 2024 12:59:02 +0000 Subject: [PATCH 07/11] Update dependencies from https://github.com/dotnet/arcade build 20240624.7 Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.Helix.Sdk , Microsoft.DotNet.SignTool , Microsoft.DotNet.XUnitExtensions From Version 8.0.0-beta.24311.3 -> To Version 8.0.0-beta.24324.7 From de9b3f2b2ca96cb1b9e5df3e4f7bdf693d9fa5c4 Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" Date: Sat, 29 Jun 2024 12:44:23 +0000 Subject: [PATCH 08/11] Update dependencies from https://github.com/dotnet/arcade build 20240626.4 Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.Helix.Sdk , Microsoft.DotNet.SignTool , Microsoft.DotNet.XUnitExtensions From Version 8.0.0-beta.24311.3 -> To Version 8.0.0-beta.24326.4 --- eng/Version.Details.xml | 16 ++++++++-------- eng/Versions.props | 4 ++-- global.json | 4 ++-- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index f5b905a2d433..79d8471c0d46 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -483,22 +483,22 @@ - + https://github.com/dotnet/arcade - 3fe41d9e97519a4e9b48293906dbf58714ea9a0d + bee35f3044609d08c40566f8a008baa4d0451a9e - + https://github.com/dotnet/arcade - 3fe41d9e97519a4e9b48293906dbf58714ea9a0d + bee35f3044609d08c40566f8a008baa4d0451a9e - + https://github.com/dotnet/arcade - 3fe41d9e97519a4e9b48293906dbf58714ea9a0d + bee35f3044609d08c40566f8a008baa4d0451a9e - + https://github.com/dotnet/arcade - 3fe41d9e97519a4e9b48293906dbf58714ea9a0d + bee35f3044609d08c40566f8a008baa4d0451a9e https://dev.azure.com/dnceng/internal/_git/dotnet-runtime diff --git a/eng/Versions.props b/eng/Versions.props index 3d33c3270349..202caa22d817 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -35,7 +35,7 @@ 7.0.0 4.0.0 7.0.0 - 8.0.0-beta.24324.7 + 8.0.0-beta.24326.4 7.0.0-preview.22423.2 8.0.0 4.3.0 @@ -210,7 +210,7 @@ 6.12.0 6.1.0 - 8.0.0-beta.24324.7 + 8.0.0-beta.24326.4 4.18.4 1.3.2 8.0.0-beta.23607.1 diff --git a/global.json b/global.json index 3299cf13efbd..9404a652c2a9 100644 --- a/global.json +++ b/global.json @@ -14,7 +14,7 @@ } }, "msbuild-sdks": { - "Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.24324.7", - "Microsoft.DotNet.Helix.Sdk": "8.0.0-beta.24324.7" + "Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.24326.4", + "Microsoft.DotNet.Helix.Sdk": "8.0.0-beta.24326.4" } } From d13a66c10b0c6094f7093c728cdf58b539c1ab0e Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" Date: Sun, 30 Jun 2024 12:43:01 +0000 Subject: [PATCH 09/11] Update dependencies from https://github.com/dotnet/arcade build 20240626.4 Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.Helix.Sdk , Microsoft.DotNet.SignTool , Microsoft.DotNet.XUnitExtensions From Version 8.0.0-beta.24311.3 -> To Version 8.0.0-beta.24326.4 From 16c4b79540ee7639b0d7fd9520db4db1f19af97b Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" Date: Mon, 1 Jul 2024 12:40:22 +0000 Subject: [PATCH 10/11] Update dependencies from https://github.com/dotnet/arcade build 20240628.2 Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.Helix.Sdk , Microsoft.DotNet.SignTool , Microsoft.DotNet.XUnitExtensions From Version 8.0.0-beta.24311.3 -> To Version 8.0.0-beta.24328.2 --- eng/Version.Details.xml | 16 ++++++++-------- eng/Versions.props | 4 ++-- global.json | 4 ++-- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index 79d8471c0d46..5d47569c296c 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -483,22 +483,22 @@ - + https://github.com/dotnet/arcade - bee35f3044609d08c40566f8a008baa4d0451a9e + 761c516b64fee3941d8909d24205ced835eed83e - + https://github.com/dotnet/arcade - bee35f3044609d08c40566f8a008baa4d0451a9e + 761c516b64fee3941d8909d24205ced835eed83e - + https://github.com/dotnet/arcade - bee35f3044609d08c40566f8a008baa4d0451a9e + 761c516b64fee3941d8909d24205ced835eed83e - + https://github.com/dotnet/arcade - bee35f3044609d08c40566f8a008baa4d0451a9e + 761c516b64fee3941d8909d24205ced835eed83e https://dev.azure.com/dnceng/internal/_git/dotnet-runtime diff --git a/eng/Versions.props b/eng/Versions.props index 202caa22d817..5d756017a838 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -35,7 +35,7 @@ 7.0.0 4.0.0 7.0.0 - 8.0.0-beta.24326.4 + 8.0.0-beta.24328.2 7.0.0-preview.22423.2 8.0.0 4.3.0 @@ -210,7 +210,7 @@ 6.12.0 6.1.0 - 8.0.0-beta.24326.4 + 8.0.0-beta.24328.2 4.18.4 1.3.2 8.0.0-beta.23607.1 diff --git a/global.json b/global.json index 9404a652c2a9..74e605301f20 100644 --- a/global.json +++ b/global.json @@ -14,7 +14,7 @@ } }, "msbuild-sdks": { - "Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.24326.4", - "Microsoft.DotNet.Helix.Sdk": "8.0.0-beta.24326.4" + "Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.24328.2", + "Microsoft.DotNet.Helix.Sdk": "8.0.0-beta.24328.2" } } From 194445444f738e80ae8035f6d0e0537eb0635506 Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" Date: Tue, 2 Jul 2024 12:57:20 +0000 Subject: [PATCH 11/11] Update dependencies from https://github.com/dotnet/arcade build 20240628.2 Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.Helix.Sdk , Microsoft.DotNet.SignTool , Microsoft.DotNet.XUnitExtensions From Version 8.0.0-beta.24311.3 -> To Version 8.0.0-beta.24328.2