Fixing "Unable to Retrieve Credentials" When Pulling Charts from ECR Public
When attempting to pull Helm charts or container images from the public Amazon ECR registry (public.ecr.aws), you may encounter the following error:
helm pull oci://public.ecr.aws/karpenter/karpenter
Error: GET "https://public.ecr.aws/v2/karpenter/karpenter/tags/list": unable to retrieve credentials
Root Cause & Solution
While the repository is public, Helm requires anonymous or token-based authentication with public.ecr.aws before it can query OCI tag lists.
Authenticate Helm to the public ECR registry (always using region us-east-1):
aws ecr-public get-login-password --region us-east-1 \
| helm registry login --username AWS --password-stdin public.ecr.aws
Once logged in, pull the chart normally: