diff --git a/index.html b/index.html index e485915ed..bac21649d 100644 --- a/index.html +++ b/index.html @@ -70,13 +70,15 @@ args: - --watch-ingress-without-class=true ... ... -
No problem. This should still keep working, but we highly recommend you to test!
In this scenario, you need to create multiple ingressClasses (see example one). But be aware that ingressClass works in a very specific way: you will need to change the .spec.controller value in your IngressClass and point the controller to the relevant ingressClass. Let's see some example, supposing that you have two Ingress Classes:
--controller-class field as follows:Ingress-Nginx-Controller-nginx1 with k8s.io/ingress-nginx1 Ingress-Nginx-Controller-nginx2 with k8s.io/ingress-nginx2 Then, when you create an Ingress Object with IngressClassName = ingress-nginx2, it will look for controllers with controller-class=k8s.io/ingress-nginx2 and as Ingress-Nginx-Controller-nginx2 is watching objects that points to ingressClass="k8s.io/ingress-nginx2, it will serve that object, while Ingress-Nginx-Controller-nginx1 will ignore the ingress object.
Bear in mind that, if your Ingress-Nginx-Controller-nginx2 is started with the flag --watch-ingress-without-class=true, then it will serve ; - objects without ingress-class - objects with the annotation configured in flag --ingress-class and same class value - and also objects pointing to the ingressClass that have the same .spec.controller as configured in --controller-class
kubectl create namespace ingress-controller-2
+No problem. This should still keep working, but we highly recommend you to test!
In this scenario, you need to create multiple ingressClasses (see example one). But be aware that ingressClass works in a very specific way: you will need to change the .spec.controller value in your IngressClass and point the controller to the relevant ingressClass. Let's see some example, supposing that you have two Ingress Classes:
--controller-class field as follows:Ingress-Nginx-Controller-nginx1 with k8s.io/ingress-nginx1 Ingress-Nginx-Controller-nginx2 with k8s.io/ingress-nginx2 Then, when you create an Ingress Object with IngressClassName = ingress-nginx2, it will look for controllers with controller-class=k8s.io/ingress-nginx2 and as Ingress-Nginx-Controller-nginx2 is watching objects that points to ingressClass="k8s.io/ingress-nginx2, it will serve that object, while Ingress-Nginx-Controller-nginx1 will ignore the ingress object.
Bear in mind that, if your Ingress-Nginx-Controller-nginx2 is started with the flag --watch-ingress-without-class=true, then it will serve ; - objects without ingress-class - objects with the annotation configured in flag --ingress-class and same class value - and also objects pointing to the ingressClass that have the same .spec.controller as configured in --controller-class
kubectl create namespace ingress-nginx-2
helm repo add ingress-nginx https://kubernetes.github.io/ingress-nginx`
helm repo update
-helm --namespace ingress-controller-2 install ingcontroller-2 ingress-nginx/ingress-nginx \
---set controller.ingressClass=ingress-class-2 \
---set controller.ingressClassResource.name=ingress-class-2 \
---set controller.ingressClassResource.controllerValue= "k8s.io/ingress-controller-2"
+helm install ingress-nginx-2 ingress-nginx/ingress-nginx \
+--namespace ingress-nginx-2 \
+--set controller.ingressClassResource.name=nginx-2 \
+--set controller.ingressClassResource.controllerValue= "k8s.io/ingress-nginx-2" \
+--set controller.ingressClassResource.enabled=true \
+--set controller.IngressClassByName=true