Skip to content

Commit

Permalink
docs(eks): remove description about incorrect requirement for vpcSubn…
Browse files Browse the repository at this point in the history
…ets (#27931)

It seems that the description for vpcSubnets in EKS Cluster class includes incorrect requirement.

https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_eks.Cluster.html#vpcsubnets
> If you want to create public load balancers, this must include public subnets.

The requirements for subnets where control plane ENIs are placed are described in the following document.

https://docs.aws.amazon.com/eks/latest/userguide/network_reqs.html#network-requirements-subnets

> The subnets that you specify when you create or update a cluster must meet the following requirements:
> 
> The subnets must each have at least six IP addresses for use by Amazon EKS. However, we recommend at least 16 IP addresses.
> The subnets can't reside in AWS Outposts, AWS Wavelength, or an AWS Local Zone. However, if you have them in your VPC, you can deploy self-managed nodes and Kubernetes resources to these types of subnets.
> The subnets can be a public or private. However, we recommend that you specify private subnets, if possible. A public subnet is a subnet with a route table that includes a route to an internet gateway, whereas a private subnet is a subnet with a route table that doesn't include a route to an internet gateway.

Other components such as nodes, Kubernetes resources or ELB can be located in different subnets from the above subnets. This is also described in the above document as below.

> You can deploy nodes and Kubernetes resources to the same subnets that you specify when you create your cluster. However, this isn't necessary. This is because you can also deploy nodes and Kubernetes resources to subnets that you didn't specify when you created the cluster.

So, this PR simply removes the incorrect sentence from CDK doc.

Closes #27923

----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
  • Loading branch information
tam0ri authored and Mike Wrighton committed Nov 13, 2023
1 parent 08c0302 commit f0f07aa
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions packages/aws-cdk-lib/aws-eks/lib/cluster.ts
Original file line number Diff line number Diff line change
Expand Up @@ -440,8 +440,6 @@ export interface CommonClusterOptions {
/**
* Where to place EKS Control Plane ENIs
*
* If you want to create public load balancers, this must include public subnets.
*
* For example, to only select private subnets, supply the following:
*
* `vpcSubnets: [{ subnetType: ec2.SubnetType.PRIVATE_WITH_EGRESS }]`
Expand Down

0 comments on commit f0f07aa

Please sign in to comment.