feat: update more than one LoadBalancer ip
Co-authored-by: kevinpollet <pollet.kevin@gmail.com>
This commit is contained in:
parent
76f42a3013
commit
498e8545b6
4 changed files with 119 additions and 23 deletions
|
@ -301,7 +301,7 @@ func (p *Provider) updateIngressStatus(ing *networkingv1beta1.Ingress, k8sClient
|
|||
return errors.New("publishedService or ip or hostname must be defined")
|
||||
}
|
||||
|
||||
return k8sClient.UpdateIngressStatus(ing, p.IngressEndpoint.IP, p.IngressEndpoint.Hostname)
|
||||
return k8sClient.UpdateIngressStatus(ing, []corev1.LoadBalancerIngress{{IP: p.IngressEndpoint.IP, Hostname: p.IngressEndpoint.Hostname}})
|
||||
}
|
||||
|
||||
serviceInfo := strings.Split(p.IngressEndpoint.PublishedService, "/")
|
||||
|
@ -326,7 +326,7 @@ func (p *Provider) updateIngressStatus(ing *networkingv1beta1.Ingress, k8sClient
|
|||
return fmt.Errorf("missing service: %s", p.IngressEndpoint.PublishedService)
|
||||
}
|
||||
|
||||
return k8sClient.UpdateIngressStatus(ing, service.Status.LoadBalancer.Ingress[0].IP, service.Status.LoadBalancer.Ingress[0].Hostname)
|
||||
return k8sClient.UpdateIngressStatus(ing, service.Status.LoadBalancer.Ingress)
|
||||
}
|
||||
|
||||
func (p *Provider) shouldProcessIngress(providerIngressClass string, ingress *networkingv1beta1.Ingress, ingressClass *networkingv1beta1.IngressClass) bool {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue