I'm having an issue while logging into ECR.
buildspec.yml
...
- echo $AWS_DEFAULT_REGION and $AWS_ACCOUNT_ID
- aws ecr get-login-password --region $AWS_DEFAULT_REGION | docker login --username AWS --password-stdin $AWS_ACCOUNT_ID.dkr.ecr.$AWS_DEFAULT_REGION.amazonaws.com
Following command return me "us-east-2" and "" ($AWS_ACCOUNT_ID is empty)
- echo $AWS_DEFAULT_REGION and $AWS_ACCOUNT_ID
so that's why I'm unable to login to ECR.