I currently work with AWS Sagemaker and try to pull prebuild images from ECR.
However, I ran into issues while pulling some images, and others worked.
I successfully logged into the corresponding accounts ECR repo.
E.g., I can pull the following image without issues:
683313688378.dkr.ecr.us-east-1.amazonaws.com/sagemaker-scikit-learn:0.23-1-cpu-py3
And I run into the following issue with the next image:
docker pull 382416733822.dkr.ecr.us-east-1.amazonaws.com/pca:1
Error response from daemon: pull access denied for 382416733822.dkr.ecr.us-east-1.amazonaws.com/pca, repository does not exist or may require 'docker login': denied: User: XXXXXXXXXX is not authorized to perform: ecr:BatchGetImage on resource: arn:aws:ecr:us-east-1:382416733822:repository/pca because no resource-based policy allows the ecr:BatchGetImage action
It seems like the resource based policy denies access.
Is it not intended to download e.g. the PCA container image?