Tuesday, September 3, 2019

Minikube TCP ingress

I've been playing around with Minikube to setup a local, single-node kubernetes cluster. But it wasn't obvious how to open a tcp to connect to a service running in the cluster.

1. Enable the minikube ingress addon. This installs a ingress-nginx controller for you in the kube-system namespace

minikube addons enable ingress

2. The ingress-nginx supports proxying tcp ports (see the docs for details), we jsut need to edit the configmap created by the minikube to forward the correct ports.

Here is an example adding tcp ingress from port 5432, to a default/postgres service on port 5432:


3. By default, the minikube ingress addon sets up ingres-nginx to use the internal network, so the ports are still not exposed to clients outside the cluster. One way around this is the change the ingress pod to use the host neowork, so the nginx listens of the host's network interface. The docs go over the pros and cons of using host ports, but it worked for my use case.

Enable host network for ingress controller:

2 comments:

  1. The 888 Casino App - Get $10 FREE + $10 Deposit Bonus
    If you have a gaming 김제 출장안마 experience, you 구리 출장샵 may 청주 출장안마 want to 천안 출장마사지 consider making some 이천 출장안마 money on it. There's something for everyone, whether it is on the casino or a live

    ReplyDelete
  2. As manufacturing processes are evolving at a speedy tempo, it has become essential for fabricators to leverage these improvements to stay aggressive. Domestic costs for steel plates in Northern Europe for the vibrating panties reviews week of October 7-14, 2022, decreased by €10/t on an ex-works foundation in the Ruhr – to €1050/t. Rolled steel producers are reducing value levels to fill the portfolio of orders.

    ReplyDelete