Update comments and UT to remove /66 restriction

The comments in cmd/kubeadm/app/phases/controlplane/manifests.go mention the
IPv6 /66 restriction, and the UT also refers to this.
This restriction was removed in PR#60089
This commit is contained in:
Robert Pothier 2018-04-18 16:01:46 -04:00
parent 828ffd5a4e
commit 8bfe7f8dae
2 changed files with 10 additions and 8 deletions

View File

@ -275,9 +275,6 @@ func getAPIServerCommand(cfg *kubeadmapi.MasterConfiguration) []string {
// If the pod network size is /113 or larger, the node CIDR will be set to the same
// size and this will be rejected later in validation.
//
// NOTE: Currently, the pod network must be /66 or larger. It is not reflected here,
// but a smaller value will fail later validation.
//
// NOTE: Currently, the design allows a maximum of 64K nodes. This algorithm splits
// the available bits to maximize the number used for nodes, but still have the node
// CIDR be a multiple of eight.

View File

@ -822,16 +822,21 @@ func TestCalcNodeCidrSize(t *testing.T) {
podSubnet: "2001:db8::/95",
expectedPrefix: "104",
},
{
name: "V6: Largest subnet currently supported",
podSubnet: "2001:db8::/66",
expectedPrefix: "80",
},
{
name: "V6: For /64 pod net, use /80",
podSubnet: "2001:db8::/64",
expectedPrefix: "80",
},
{
name: "V6: For /48 pod net, use /64",
podSubnet: "2001:db8::/48",
expectedPrefix: "64",
},
{
name: "V6: For /32 pod net, use /48",
podSubnet: "2001:db8::/32",
expectedPrefix: "48",
},
}
for _, test := range tests {
actualPrefix := calcNodeCidrSize(test.podSubnet)