'toomanyrequests: Rate exceeded on ECR

Recently we are facing rate-limiting issues on ECR, error is toomanyrequests: Rate exceeded, We have a docker image with ~40 layer when we do a docker push some time total api transactions will be 40-15 but some time it will be 100-150 transactions. Why this scenario occurs as image layer nothing is changed but api transactions like InitiateLayerUpload differs in huge amount



Solution 1:[1]

Have you tried logging into the public ecr?

aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws

See documentation: https://docs.aws.amazon.com/AmazonECR/latest/public/public-registries.html#public-registry-auth

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 bolmaster2