k3s/federation/pkg
Kubernetes Submit Queue 631612028a Merge pull request #37323 from nikhiljindal/firstClusterPR
Automatic merge from submit-queue

Fixing the logic to select first cluster in federated ingress controller

Ref https://github.com/kubernetes/kubernetes/issues/36074.

Before this change, ingress controller was using cluster with clusterIndex = 0 as the first cluster to create the ingress in.
But the ordering of clusters can change and hence ingress controller ended up creating the ingress in multiple clusters.
This PR fixes it by using an annotation on federated ingress. Controller now picks up a cluster randomly as the first cluster and creates ingress there. This clusters name is stored as an annotation on the federated ingress. Contoller does not create an ingress in any other cluster if this annotation is set on the federated ingress and IP has not been propagated. Once IP has been propagated, controller creates the ingress in all clusters.

cc @kubernetes/sig-cluster-federation @madhusudancs
2016-11-29 09:00:14 -08:00
..
dnsprovider generated: refactor 2016-11-23 22:30:47 -06:00
federation-controller Merge pull request #37323 from nikhiljindal/firstClusterPR 2016-11-29 09:00:14 -08:00
kubefed generated: refactor 2016-11-23 22:30:47 -06:00