-
Notifications
You must be signed in to change notification settings - Fork 72
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[main] Update dependencies from dotnet/arcade (#404)
Microsoft.SourceBuild.Intermediate.arcade , Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.XliffTasks From Version 9.0.0-beta.24266.1 -> To Version 9.0.0-beta.24272.5 Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
- Loading branch information
1 parent
95602ba
commit 3cb13be
Showing
8 changed files
with
117 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,11 @@ | ||
<!-- Licensed to the .NET Foundation under one or more agreements. The .NET Foundation licenses this file to you under the MIT license. --> | ||
<Project> | ||
|
||
<PropertyGroup> | ||
<ImportDirectoryBuildTargets>false</ImportDirectoryBuildTargets> | ||
<ImportDirectoryPackagesProps>false</ImportDirectoryPackagesProps> | ||
</PropertyGroup> | ||
|
||
<Import Project="Sdk.props" Sdk="Microsoft.DotNet.Arcade.Sdk" /> | ||
|
||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -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" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters