Nginx ingress not working on AWS instances (multi-OS kubernetes cluster)

9/16/2019

I have created multi-OS Kubernetes cluster containing one Linux(manager) and two windows19 worker nodes.

Important: I am NOT using EKS service, but self-generated ec2 instances.

I am trying to expose two web services (web1 & web2) via URI routing so I have picked Nginx ingress for the job.

Long story short;
I have followed this documentation:

https://github.com/kubernetes/ingress-nginx/blob/master/docs/deploy/index.md#aws

after long integration efforts, I managed to get the cluster functional, deploy 2 web apps
and to deploy the ingress controller (via 'helm') on the Linux node only:

NAME                                     READY   UP-TO-DATE   AVAILABLE   AGE
my-nginx-nginx-ingress-controller        1/1     1            1           17m
my-nginx-nginx-ingress-default-backend   1/1     1            1           17m
web1                                     1/1     1            1           4h5m
web2                                     1/1     1            1           4h5m

My question comes to this-
as far as I know (and I might be wrong) the following step from the guide above should create a load balancer in front of my ingress (at my AWS environment):

kubectl apply -f https://raw.githubusercontent.com/kubernetes/ingress-nginx/master/deploy/static/provider/aws/service-l4.yaml
kubectl apply -f https://raw.githubusercontent.com/kubernetes/ingress-nginx/master/deploy/static/provider/aws/patch-configmap-l4.yaml

However, I can't see any new load balancer at AWS and my service won't allocate external-IP for my service:

NAME                                     TYPE           CLUSTER-IP       EXTERNAL-IP   PORT(S)                      AGE
kubernetes                               ClusterIP      10.96.0.1        <none>        443/TCP                      4d3h
my-nginx-nginx-ingress-controller        LoadBalancer   10.109.225.243   <pending>     80:30814/TCP,443:30973/TCP   23m
my-nginx-nginx-ingress-default-backend   ClusterIP      10.104.134.115   <none>        80/TCP                       23m
web1                                     ClusterIP      10.108.177.197   <none>        80/TCP                       19h
web2                                     ClusterIP      10.103.60.249    <none>        80/TCP                       19h
kubectl get svc --all-namespaces | grep ingress

default         my-nginx-nginx-ingress-controller        LoadBalancer  10.109.225.243   <pending>     80:30814/TCP,443:30973/TCP   2d21h
default         my-nginx-nginx-ingress-default-backend   ClusterIP      10.104.134.115   <none>        80/TCP                       2d21h
ingress-nginx   ingress-nginx                            LoadBalancer   10.101.119.16    <pending>     80:32626/TCP,443:31642/TCP   2d21h

I probably don't understand this ingress functionality-
- Can it work on multi-OS environment? (controller on Linux node only)
- Is the fact that I don't use native EKS functions make it impossible to attach a proper L3/4 LB?

Spent 2 days trying to make it work and got stuck. I'll be glad to hear some insights, including alternative service-exposure methods.

-- Ron Gimpelevich
kubernetes
kubernetes-ingress

0 Answers