<p>I am learning kubernetes by playing with minikube.</p>

<p>This is my pod deployment file which is fine.</p>

<pre><code>apiVersion: apps/v1
kind: Deployment
metadata:
  name: my-deployment
spec:
  replicas: 2
  selector:
    matchLabels:
      component: web
  template:
    metadata:
      labels:
        component: web
    spec:
      containers:
        - name: myapp
          image: myid/myimage
</code></pre>

<p>I am exposing the above pods using NodePort. I am able to access using minikube IP at port 30002.</p>

<pre><code>apiVersion: v1
kind: Service
metadata:
  name: my-ip-service
spec:
  type: NodePort
  externalIPs:
  - 192.168.99.100
  selector:
    component: web
  ports:
    - port: 3000
      nodePort: 30002
      targetPort: 8080
</code></pre>

<p>Now i would like to use ingress to access the application at port 80 which will forward the request the ip-service at port 3000. It does NOT work</p>

<pre><code>apiVersion: extensions/v1beta1
kind: Ingress
metadata:
  name: test-ingress
spec:
  backend:
    serviceName: my-ip-service
    servicePort: 3000
</code></pre>

<p>If i try to access to ingress, address is blank. </p>

<pre><code>NAME           HOSTS   ADDRESS   PORTS   AGE
test-ingress   *                 80      41m
</code></pre>

<p>How to use ingress with minikube? Or how to bind the minikube ip with ingress service - so that the app can be exposed outside without using nodeport</p>

KitKarson
<p>I think you are missing the ingress controller resource on minikube itself. There are many possible ways to create an ingress-controller resource on K8s , but i think for you the best way to start on minikube is to follow <a href="https://kubernetes.github.io/ingress-nginx/deploy/#minikube" rel="nofollow noreferrer">this</a> documentation.</p>

<p>Don't forget to read about <a href="https://kubernetes.io/docs/concepts/services-networking/ingress/" rel="nofollow noreferrer">Ingress</a> in general once you get this working.</p>
