Remove providerless tag in controller_test.go
Signed-off-by: Davanum Srinivas <davanum@gmail.com>
This commit is contained in:
		| @@ -22,6 +22,8 @@ import ( | ||||
| 	"net" | ||||
| 	"time" | ||||
|  | ||||
| 	"k8s.io/kubernetes/pkg/controller/nodeipam/ipam/cidrset" | ||||
|  | ||||
| 	v1 "k8s.io/api/core/v1" | ||||
| 	metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" | ||||
| 	"k8s.io/apimachinery/pkg/fields" | ||||
| @@ -160,3 +162,14 @@ func ipnetToStringList(inCIDRs []*net.IPNet) []string { | ||||
| 	} | ||||
| 	return outCIDRs | ||||
| } | ||||
|  | ||||
| // occupyServiceCIDR removes the service CIDR range from the cluster CIDR if it | ||||
| // intersects. | ||||
| func occupyServiceCIDR(set *cidrset.CidrSet, clusterCIDR, serviceCIDR *net.IPNet) error { | ||||
| 	if clusterCIDR.Contains(serviceCIDR.IP) || serviceCIDR.Contains(clusterCIDR.IP) { | ||||
| 		if err := set.Occupy(serviceCIDR); err != nil { | ||||
| 			return err | ||||
| 		} | ||||
| 	} | ||||
| 	return nil | ||||
| } | ||||
|   | ||||
| @@ -165,17 +165,6 @@ func (c *Controller) Run(ctx context.Context) { | ||||
| 	<-ctx.Done() | ||||
| } | ||||
|  | ||||
| // occupyServiceCIDR removes the service CIDR range from the cluster CIDR if it | ||||
| // intersects. | ||||
| func occupyServiceCIDR(set *cidrset.CidrSet, clusterCIDR, serviceCIDR *net.IPNet) error { | ||||
| 	if clusterCIDR.Contains(serviceCIDR.IP) || serviceCIDR.Contains(clusterCIDR.IP) { | ||||
| 		if err := set.Occupy(serviceCIDR); err != nil { | ||||
| 			return err | ||||
| 		} | ||||
| 	} | ||||
| 	return nil | ||||
| } | ||||
|  | ||||
| type nodeState struct { | ||||
| 	t Timeout | ||||
| } | ||||
|   | ||||
| @@ -1,6 +1,3 @@ | ||||
| //go:build !providerless | ||||
| // +build !providerless | ||||
|  | ||||
| /* | ||||
| Copyright 2017 The Kubernetes Authors. | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Davanum Srinivas
					Davanum Srinivas