I have a similar issue as below with exposing kubernetes services via type: LoadBalancer on my local minikube cluster.
LoadBalancer support
I saw that there is a workaround for this and it can be fixed via running the command minikube tunnel.
Minikube Tunnel Design Doc
However the command 'minikube tunnel' doesn't work for me and it throws an error of "Unknown command". Does anyone know if i am missing anything?
Thanks for the help!
The tunnel feature is quite new and may not be in your minikube version so try upgrading to latest minikube
Related
I try to run an exposed service on my Macbook(M1). However, I failed to browse the service locally. What could be the root cause?
Please see the attached images.
Is the shortcut command for fetching the minikube IP and a service’s NodePort not working?
minikube service --url <service-name>
There are some limitations with minikube running with docker driver on MacOS. Please see this GitHub issue.
There are two options at least (more, but these are simple to do):
use the minikube tunnel
Tunnel is used to expose the service from inside of the VM where minikube is running to the host machine's network. Please refer to access applications in minikube.
This is how minikube_IP:NodePort transforms to localhost:different_port.
start minikube with VirtualBox driver to get a proper IP (if you
really need to access your service on NodePort), below the command
how to start it with VirtualBox driver (this should be installed on
your machine):
minikube start --driver=VirtualBox
I've been encountering few major issues with my K8s cluster:
Windows pods running on my Windows nodes are unable to communicate (internally within the cluster) with my linux pods or services. BUT my Linux pods are able to communicate with my Windows pods.
Windows pods are also unable to resolve dns names for any service within K8s
Windows pods are unable to resolve domain names for anything on the internet. Though after opening a shell in the windows pod and manually adding 8.8.8.8 as a DNS server, it would start working
Windows pods are unable to communicate with other pods using the FQDN or ClusterIPs of services created for windows pods.
Things I've verified:
CoreDNS is running
I see no warnings or errors in logs or k8s description of either CoreDNS or Calico pods
I suspect that the issue might be with calico, but I'm quite lost on where to even begin now to troubleshoot these issues. Googling turned up this similar issue, but I've been unsuccessful so far
I've also tried running the following command, but no luck:
kubectl -n kube-system rollout restart deployment coredns
Any ideas any what I can try to take a look at? below is a diagram that I created to try and help visually explain my issue:
minikube on a vm, vm is installed on windows10.
how to access minikube's dashboard from windows10?
I heard and doing some investigate about nodeport but still asking.
I guess the simplest way to do this is kubectl proxy.
You can find an instruction in official Kubernetes documentation
I am new to kubernetes and trying to throw together a quick learning project, however I am confused on how to connect a pod to a local service.
I am storing some config in a ZooKeeper instance that I am running on my host machine, and am trying to connect a pod to it to grab config.
However I cannot get it to work, I've tried the magic "10.0.2.2" that I've read about, but that did not work. I also tried creating a service and endpoint, but again to no avail. Any help would be appreciated, thanks!
Also, for background I'm using minikube on macOS with the hyperkit vm-driver.
We deployed a containerized app by pulling a public docker image from docker hub and were able to get a pod running at a server running at 172.30.105.44. Hitting this IP from a rest client or curl/pinging the IP gives no response. Can someone please guide us where we are going wrong?
Firstly, find out the IP of your node by executing the command
kubectl get nodes
Get the information related to the pod running by executing the command kubectl describe services <pod-name>
Make a note of the field NodePort from here.
To access your service that is already running, hit the endpoint - nodeIP:NodePort.
You can now access your service successfully!
I am not sure where you have deployed (AWS, GKE, Bare) but you should make sure you have the following:
https://kubernetes.io/docs/user-guide/ingress/
https://kubernetes.io/docs/user-guide/services/
Ingress will work out of the box on GKE, but with an AWS installation, you may need to make sure you have nginx-ingress pods running.