Docker Hub Rate Limiting
As of November 1, 2020, Docker Hub enabled rate limits based on the originating IP address. Since CircleCI runs jobs from a shared pool of IPs, it is strongly recommended to use authenticated Docker pulls with Docker Hub to avoid encountering rate limits.
Identifying this error can be done by examining the Spin Up Environment
step of your build output for a toomanyrequests:Too Many Requests
error message.
Solutions
Using authentication for Docker Hub in your builds is the best way to avoid being rate limited for Docker image Pulls. The first suggestion is to create a Context for your Docker Hub credentials to incorporate in your config.yml
.
Example config:
You may also use a per-project Environment Variables as shown here.
Alternative solutions can also be found here in our Documentation here.
Below is an example of a build failure due to encountering the Docker rate limit.
Comments
Article is closed for comments.