Esempio n. 1
0
func buildServiceStatus(ingresses [][]string) v1.LoadBalancerStatus {
	status := v1.LoadBalancerStatus{
		Ingress: []v1.LoadBalancerIngress{},
	}
	for _, element := range ingresses {
		ingress := v1.LoadBalancerIngress{IP: element[0], Hostname: element[1]}
		status.Ingress = append(status.Ingress, ingress)
	}
	return status
}
func deepCopy_v1_LoadBalancerStatus(in v1.LoadBalancerStatus, out *v1.LoadBalancerStatus, c *conversion.Cloner) error {
	if in.Ingress != nil {
		out.Ingress = make([]v1.LoadBalancerIngress, len(in.Ingress))
		for i := range in.Ingress {
			if err := deepCopy_v1_LoadBalancerIngress(in.Ingress[i], &out.Ingress[i], c); err != nil {
				return err
			}
		}
	} else {
		out.Ingress = nil
	}
	return nil
}