Azure DevOps AzCopy Authentication failed it is either not correct or expired or does not have the correct permission

0 votes
To upload the build artifacts to the blob container I used the task Azure file copy. But an error occurred :

0.0 %, 0 Done, 0 Failed, 1 Pending, 0 Skipped, 1 Total,
INFO: Authentication failed, it is either not correct, or expired, or does not have the correct permission -> github.com/Azure/azure-storage-blob-go/azblob.newStorageError, /home/vsts/go/pkg/mod/github.com/!azure/azure-storage-blob-go@v0.10.1-0.20201022074806-8d8fc11be726/azblob/zc_storage_error.go:42
===== RESPONSE ERROR (ServiceCode=AuthorizationPermissionMismatch) =====
Description=This request is not authorized to perform this operation using this permission.
RequestId:ae545517-501e-00ce-0798-ea489e000000
Time:2021-12-06T11:54:25.0571292Z, Details:
   Code: AuthorizationPermissionMismatch
   PUT mybloburl?blockid=YjA4YjIzN2UtODJhMC1mMjQzLTUwOGYtNmYxNDcwOGJjZmY0&comp=block&timeout=901
   Authorization: REDACTED
   Content-Length: [8388608]
   User-Agent: [TFS_useragent AzCopy/10.8.0 Azure-Storage/0.10 (go1.13; Windows_NT)]
   X-Ms-Client-Request-Id: [65465-83ea-4410-450e-dd5b722b6cb3]
   X-Ms-Version: [2019-12-12]
   --------------------------------------------------------------------------------
   RESPONSE Status: 403 This request is not authorized to perform this operation using this permission.

The YAML file content I used for this task:
steps:
- task: AzureFileCopy@4
  displayName: 'AzureBlob File Copy'
  inputs:
    SourcePath: '$(Build.ArtifactStagingDirectory)/myfile.zip'
    azureSubscription: 'my-azure-connection'
    Destination: AzureBlob
    storage: mystorage
    ContainerName: mycontainer

Can someone help me with this issue?
Apr 14, 2022 in Other DevOps Questions by Kichu
• 19,040 points
1,436 views

No answer to this question. Be the first to respond.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.

Related Questions In Other DevOps Questions

0 votes
1 answer

Is it possible to have a link to raw content of file in Azure DevOps

Sure, here's the call for the rests: GET ...READ MORE

answered Feb 10, 2022 in Other DevOps Questions by Bhavitha
• 1,000 points
712 views
0 votes
1 answer

calculate the length of the storage container - Azure blob storage

You can use the following code: $resourceGroup = ...READ MORE

answered Oct 30, 2019 in Azure by Waheem

edited Oct 7, 2021 by Sarfaraz 2,125 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP