By kjhgfdssssa
I’m very new to Kubernetes and I’m trying to pull a container from a private container registry.
The private container registry hostname is internal and only resolvable using our internal DNS.
Failed to pull image “this.is.private/awesome:latest”: rpc error: code = Unknown desc = Error response from daemon: Get https://this.is.private/v2/: dial tcp: lookup this.is.private on 67.207.67.2:53: no such host
How can I tell Kubernetes to use our internal DNS name server when it tries to resolve this.is.private?
Remember: this is a managed instance of Kubernetes and this error is before the pods are online.
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Heya,
Just came across this answer and decided to write some general guidelines for anyone who comes across this in the future despite the old question.
Unfortunately, DigitalOcean’s Managed Kubernetes service does not currently support custom DNS configurations during the pod initialisation process. This includes DNS resolution for pulling images from private repositories.
However, you can use a couple of workarounds. One possible solution is to use a public domain name for your registry and then secure it using SSL+'Basic authentication. Another workaround could be using a private Docker registry and importing the image as a Docker data volume, which can then be used on any new instances or nodes.
For more detailed explanations, you can refer to the official DigitalOcean documentation here.
Hope that this helps!
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.