Skip to content

Commit

Permalink
Remove az login
Browse files Browse the repository at this point in the history
  • Loading branch information
adityapatwardhan committed Oct 10, 2023
1 parent 0d893fd commit 51cd9ba
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ steps:
$azcopy = Find-AzCopy
Write-Verbose -Verbose "Found AzCopy: $azcopy"
& $azcopy login --service-principal --application-id $(PowerShellReleaseSPN)
& $azcopy cp https://$(StorageAccount).blob.core.windows.net/$(AzureVersion) $(System.ArtifactsDirectory) --recursive
$packagesPath = Get-ChildItem -Path $(System.ArtifactsDirectory)\*.deb -Recurse -File | Select-Object -First 1 -ExpandProperty DirectoryName
Expand All @@ -27,7 +26,7 @@ steps:
displayName: Download Azure Artifacts
retryCountOnTaskFailure: 2
env:
AZCOPY_SPA_CLIENT_SECRET: $(PowerShellReleaseSPNSecret)
AZCOPY_AUTO_LOGIN_TYPE: MSI

- pwsh: |
Get-ChildItem $(System.ArtifactsDirectory)\* -recurse | Select-Object -ExpandProperty FullName
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,11 @@ steps:
$azcopy = Find-AzCopy
Write-Verbose -Verbose "Found AzCopy: $azcopy"
& $azcopy login --service-principal --application-id $(PowerShellReleaseSPN)
& $azcopy cp https://$(StorageAccount).blob.core.windows.net/$(AzureVersion)/* $(System.ArtifactsDirectory) --recursive
displayName: Download Azure Artifacts
env:
AZCOPY_SPA_CLIENT_SECRET: $(PowerShellReleaseSPNSecret)
AZCOPY_AUTO_LOGIN_TYPE: MSI

- pwsh: |
Get-ChildItem $(System.ArtifactsDirectory)\* -recurse | Select-Object -ExpandProperty Name
Expand Down
5 changes: 1 addition & 4 deletions tools/releaseBuild/azureDevOps/templates/vpackReleaseJob.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,16 +38,13 @@ jobs:
Import-module '$(BUILD.SOURCESDIRECTORY)/build.psm1'
$azcopy = Find-AzCopy
Write-Verbose -Verbose "Found AzCopy: $azcopy"
& $azcopy login --service-principal --application-id $(PowerShellReleaseSPN)
Write-Host "running: $azcopy cp https://$(StorageAccount).blob.core.windows.net/$(AzureVersion)/PowerShell-$(Version)-win-${{ parameters.architecture }}.zip $(System.ArtifactsDirectory)"
& $azcopy cp https://$(StorageAccount).blob.core.windows.net/$(AzureVersion)/PowerShell-$(Version)-win-${{ parameters.architecture }}.zip $(System.ArtifactsDirectory)
displayName: 'Download Azure Artifacts'
retryCountOnTaskFailure: 2
env:
AZCOPY_SPA_CLIENT_SECRET: $(PowerShellReleaseSPNSecret)
AZCOPY_AUTO_LOGIN_TYPE: MSI
- pwsh: 'Get-ChildItem $(System.ArtifactsDirectory)\* -recurse | Select-Object -ExpandProperty Name'
displayName: 'Capture Artifact Listing'
Expand Down

0 comments on commit 51cd9ba

Please sign in to comment.