nip.io not filtered by my DNS provider
ybart opened this issue · 4 comments
My DNS provider filters local IPs, so this prevented *.nip.io address to work correctly and caused the following error instead :
➜ ~ curl http://deis.192.168.64.2.nip.io/v2/ && echo
curl: (6) Could not resolve host: deis.192.168.64.2.nip.io
I first tried to use xip.io
instead before realizing this sas caused by my DNS provider which, of course, failed to solve the problem.
I could thinks of these workarounds :
- In documentation, in case of failure with *.nip.io, request the user to change DNS provider and use another provider such as Google and update DNS settings to something like 8.8.8.8 / 8.8.4.4.
- Add entries to
/etc/hosts
Maybe there are more friendly solutions. However, I am not sure these work-around are OK for all use-cases.
So for background context, we configure DNS to nip.io and xip.io only for development/testing purposes on minikube. For other cloud platforms we use an actual wildcard route with their DNS provider, and in Configuring DNS we don't even make a mention to nip.io/xip.io.
There's not many DNS providers that block xip and nip.io so I think this is a very small subset of devs that would hit this roadblock, so I'd partially be against telling users to switch DNS providers just to run Workflow.
Another potential solution is to install and configure dnsmasq
to point at the node's IP. However, that only works on Linux/macOS and not Windows. I'm not sure of a good cross-system solution other than nip.io/xip.io (or actually setting up proper DNS routes).
I agree dnsmasq
is far superior as it does not require to mess with DNS settings and it provides a wildcard local domain. It looks like a good alternative to nip.io
for a development/testing environment for macOS and Linux. For Windows, it looks like Acrylic DNS Proxy can also provide such a local wildcard.
On macOS, I used these instructions (see. https://gist.github.com/eloypnd/5efc3b590e7c738630fdcf0c10b68072) :
brew install dnsmasq
echo "address=/deis.local/`minikube ip`" >> /usr/local/etc/dnsmasq.conf
sudo brew services start dnsmasq
sudo mkdir /etc/resolver
echo nameserver 127.0.0.1 | sudo tee /etc/resolver/local
Then logged out / login session.
Maybe we can mention alternatives in case of nip.io
failure and link to details in minikube docs ?
Maybe we can mention alternatives in case of nip.io failure and link to details in minikube docs ?
@ybart I think that is a great idea -- a PR would be welcome! Perhaps in the minikube section and potentially in the deploy-an-app section?