3
votes

I have a setup of kubernetes on a coreos baremetal. For now I did the connection from outside world to service with a nginx reverse-proxy.

I'm trying the new Ingress resource. for now I have added a simple ingress:

apiVersion: extensions/v1beta1
kind: Ingress
metadata:
  name: kube-ui
spec:
  backend:
    serviceName: kube-ui
    servicePort: 80

that starts like this:

INGRESS
NAME      RULE      BACKEND      ADDRESS
kube-ui   -         kube-ui:80

My question is how to connect from the outside internet to that ingress point as this resource have no ADDRESS ... ?

2
==> the problems seems to come from Ingress Controller that is not implemented for meThibault Deheurles

2 Answers

3
votes

POSTing this to the API server will have no effect if you have not configured an Ingress controller. You need to choose the ingress controller implementation that is the best fit for your cluster, or implement one. Examples and instructions can be found here.

0
votes

check this gist

This is for the ingress-nginx, not kubernetes-ingress

  1. Pre-requirement
    kubectl apply -f https://raw.githubusercontent.com/kubernetes/ingress-nginx/master/deploy/static/mandatory.yaml
  1. Exposing hostNetwork (hope you know what you are doing. As documented, other than this, you can use nodePort or loadbalancer.)
    kubectl edit deployment.apps/nginx-ingress-controller -n ingress-nginx

add

template:
  spec:
    hostNetwork: true
  1. port forwarding
   apiVersion: v1
   kind: ConfigMap
   metadata:
     name: tcp-services
     namespace: ingress-nginx
   data:
     9000: "default/example-go:8080"
  1. Also, you can use ingress object to expose the service