minikube: ingress addon is not properly assigning ip for ingresses on windows
Minikube version (use minikube version): v0.28.0
- OS (e.g. from /etc/os-release): Windows 10
- VM Driver (e.g.
cat ~/.minikube/machines/minikube/config.json | grep DriverName): virtualbox - ISO version (e.g.
cat ~/.minikube/machines/minikube/config.json | grep -i ISOorminikube ssh cat /etc/VERSION): iso/minikube-v0.28.0.iso - Install tools: chocolatey
What happened: After running minikube addons enable ingress, and then kubectl creating an ingress, if you run kubectl get ing the assigned address is 10.0.2.15 and when i add this ip into my /etc/hosts file with the corresponding host, it does not hit my nginx controller running on my minikube
What you expected to happen: The Ingress resource should be assigned the address of the minikube ip address. When I sub in the minikube ip address into the host file instead of the ip that shows up when i run kubectl get ing, then everything works correctly and i can hit the nginx controller on my minikube. When I run these exact same commands on my mac it automatically assigns the ip of the minikube as the address, so i think this is a windows specific issue.
How to reproduce it (as minimally and precisely as possible): on a windows os, run minikube addons enable ingress, and then create and ingress resource and look at the address it gives you.
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Reactions: 5
- Comments: 33 (2 by maintainers)
Instead of editing your /hosts/etc, you can also make use of the free DNS-service nip.io. So, in your ingress.yml you map your service on hostname ‘foo.192.168.99.100.nip.io’. Afterwards you point your browser to that URL and it will resolve to 192.168.99.100:xxxx and it will show your service/ingress. Eg: my ingresses:
This makes life already a bit easier.
i face the same issue on Mac
Bumping for visibility, this is happening to me on Mac OS
10.14.4Mojave withminikube v1.0.0@tkautenburger using the minikube IP works (that’s what you’re doing with the /etc/hosts file). However, the problem still remains, the Ingress controller doesn’t get the minikube IP (it gets 10.0.2.15 instead)