Surely, most of people would have experienced this. The setup is like below
My Laptop (IP: 192.168.1.10) => Dev Linux Server ((IP: 192.168.1.20)) => minikube kubernetes (Control Plane: https://192.168.48.2:8443)
I’ve setup quite lot of my development work and all good to access from the “Dev Linux Server”
But when it comes to access them from “My Laptop”, it is quite painful
Below are the various options I tried (and issues)
- K8s Service LoadBalancer => Works perfectly from “Dev Server”. External IP I tried to match with my LAN, but still cannot access from “My Laptop”
- K8s Service ClientIP and minikube tunnel => Works perfectly from “Dev Server”. Can’t still reach from “My laptop”
- SSH port forwarding => Works perfectly for non-https from “My laptop”. But when it comes to https services/ingress, the Browser doesn’t like as the host differs from cert due to HSTS issues
- K8s port forwarding & binding to 0.0.0.0: => Still Problem for https service/ingress
- Nginx Ingress Controller => Works perfectly from “Dev Server” using curl. But same problem using port-forwarding for https service/ingress
Basically, I’m looking for a way for a K8S service
or ingress
to be accessed from “My Laptop” for all type of traffic (http & https)
Is there a genuine way to expose using minikube (ie. any way to get a LAN provided DHCP IP for LoadBalancer or Ingress Controller similar to cloud providers giving an external IP)
Cluster information:
Kubernetes version:
Installation method: minikube
Host OS: Linux Ubuntu 18.04
CNI and version: Server Version: version.Info{Major:"1", Minor:"22", GitVersion:"v1.22.2", GitCommit:"8b5a19147530eaac9476b0ab82980b4088bbc1b2", GitTreeState:"clean", BuildDate:"2021-09-15T21:32:41Z", GoVersion:"go1.16.8", Compiler:"gc", Platform:"linux/amd64"}