I was having issues having my docker images uploading to Google Container Registry. This has happened to me on a few occassions and I couldn’t figure out what was wrong and then when it started working again I didn’t know what fixed it.
This past Wednesday it happened to me again. I tried to use the simple command:
gcloud docker -- push gcr.io/super-cool-project/projects-nginx:1.0.0
And it sat there for a couple minutes until I got this error:
Post https://us.gcr.io/v2/super-cool-project/blobs/uploads/: dial tcp xx.xxx.xx.xx:xxx: i/o timeout
Pretty helpful huh? After I got this message I did a bunch of research and came across Google’s documentation for the container registry. It wasn’t helpful either. https://cloud.google.com/container-registry/docs/troubleshooting
After diving into the issue for a few hours I came across a similar issue with Docker itself.
How to really fix it:
- Open up your network preferences on your Mac (these should work for other OSes as well)
- Click on “advanced”
- Click the “DNS” tab
- Click the “+” button to add a new DNS servers
- Enter in the following values and click save
8.8.8.8
That’s it. Try the command again and forever you will be golden.
Leave a Reply
You must be logged in to post a comment.