I get the following error when using the ECRPushImage@1 task to push and image to my AWS ECR.
Failed to obtain authorization token to log in to ECR, error: UnrecognizedClientException: The security token included in the request is invalid
The full log in Azure DevOps looks like this
Starting: ECRPushImage
==============================================================================
Task : Amazon ECR Push
Description : Push a Docker image to an Amazon Elastic Container Registry on AWS
Version : 1.14.0
Author : Amazon Web Services
Help : Please refer to [Amazon Elastic Container Registry](https://docs.aws.amazon.com/AmazonECR/latest/userguide/) documentation for working with this service.
More information on this task can be found in the [task reference](https://docs.aws.amazon.com/vsts/latest/userguide/ecr-pushimage.html).
####Task Permissions
This task requires permissions to call the following AWS service APIs (depending on selected task options, not all APIs may be used):
* ecr:DescribeRepositories
* ecr:CreateRepository
* ecr:GetAuthorizationToken
==============================================================================
Configuring credentials for task
...configuring AWS credentials from service endpoint '[redacted]'
...configuring AWS credentials from service endpoint '[redacted]'
...endpoint defines role-based credentials for role ***.
Configuring region for task
...configured to use region ap-southeast-4, defined in task.
Pushing image 'discord-musicbot:89'
Obtaining authentication token for ECR login
##[error]Error: Failed to obtain authorization token to log in to ECR, error: UnrecognizedClientException: The security token included in the request is invalid
Finishing: ECRPushImage
Describe the bug
I get the following error when using the
ECRPushImage@1
task to push and image to my AWS ECR.The full log in Azure DevOps looks like this
To reproduce
Expected behavior
Obtaining an authentication token for ECR login should be successful and the image should be pushed to the container repository.
Screenshots
Your Environment
Additional context
Azure-DevOps
and created an access key and secret. Those have been put into the service connection in Azure DevOps.ap-southeast-4
(Melbourne)["*"]
but it changes nothing