Class CfnCluster.Builder

java.lang.Object
software.amazon.awscdk.services.eks.CfnCluster.Builder
All Implemented Interfaces:
software.amazon.jsii.Builder<CfnCluster>
Enclosing class:
CfnCluster

@Stability(Stable) public static final class CfnCluster.Builder extends Object implements software.amazon.jsii.Builder<CfnCluster>
A fluent builder for CfnCluster.
  • Method Details

    • create

      @Stability(Stable) public static CfnCluster.Builder create(Construct scope, String id)
      Parameters:
      scope -
      • scope in which this resource is defined.
      This parameter is required.
      id -
      • scoped id of the resource.
      This parameter is required.
      Returns:
      a new instance of CfnCluster.Builder.
    • resourcesVpcConfig

      @Stability(Stable) public CfnCluster.Builder resourcesVpcConfig(IResolvable resourcesVpcConfig)
      The VPC configuration that's used by the cluster control plane.

      Amazon EKS VPC resources have specific requirements to work properly with Kubernetes. For more information, see Cluster VPC Considerations and Cluster Security Group Considerations in the Amazon EKS User Guide . You must specify at least two subnets. You can specify up to five security groups, but we recommend that you use a dedicated security group for your cluster control plane.

      Updates require replacement of the SecurityGroupIds and SubnetIds sub-properties.

      Parameters:
      resourcesVpcConfig - The VPC configuration that's used by the cluster control plane. This parameter is required.
      Returns:
      this
    • resourcesVpcConfig

      @Stability(Stable) public CfnCluster.Builder resourcesVpcConfig(CfnCluster.ResourcesVpcConfigProperty resourcesVpcConfig)
      The VPC configuration that's used by the cluster control plane.

      Amazon EKS VPC resources have specific requirements to work properly with Kubernetes. For more information, see Cluster VPC Considerations and Cluster Security Group Considerations in the Amazon EKS User Guide . You must specify at least two subnets. You can specify up to five security groups, but we recommend that you use a dedicated security group for your cluster control plane.

      Updates require replacement of the SecurityGroupIds and SubnetIds sub-properties.

      Parameters:
      resourcesVpcConfig - The VPC configuration that's used by the cluster control plane. This parameter is required.
      Returns:
      this
    • roleArn

      @Stability(Stable) public CfnCluster.Builder roleArn(String roleArn)
      The Amazon Resource Name (ARN) of the IAM role that provides permissions for the Kubernetes control plane to make calls to AWS API operations on your behalf.

      For more information, see Amazon EKS Service IAM Role in the Amazon EKS User Guide .

      Parameters:
      roleArn - The Amazon Resource Name (ARN) of the IAM role that provides permissions for the Kubernetes control plane to make calls to AWS API operations on your behalf. This parameter is required.
      Returns:
      this
    • encryptionConfig

      @Stability(Stable) public CfnCluster.Builder encryptionConfig(IResolvable encryptionConfig)
      The encryption configuration for the cluster.

      Parameters:
      encryptionConfig - The encryption configuration for the cluster. This parameter is required.
      Returns:
      this
    • encryptionConfig

      @Stability(Stable) public CfnCluster.Builder encryptionConfig(List<? extends Object> encryptionConfig)
      The encryption configuration for the cluster.

      Parameters:
      encryptionConfig - The encryption configuration for the cluster. This parameter is required.
      Returns:
      this
    • kubernetesNetworkConfig

      @Stability(Stable) public CfnCluster.Builder kubernetesNetworkConfig(IResolvable kubernetesNetworkConfig)
      The Kubernetes network configuration for the cluster.

      Parameters:
      kubernetesNetworkConfig - The Kubernetes network configuration for the cluster. This parameter is required.
      Returns:
      this
    • kubernetesNetworkConfig

      @Stability(Stable) public CfnCluster.Builder kubernetesNetworkConfig(CfnCluster.KubernetesNetworkConfigProperty kubernetesNetworkConfig)
      The Kubernetes network configuration for the cluster.

      Parameters:
      kubernetesNetworkConfig - The Kubernetes network configuration for the cluster. This parameter is required.
      Returns:
      this
    • logging

      @Stability(Stable) public CfnCluster.Builder logging(IResolvable logging)
      The logging configuration for your cluster.

      Parameters:
      logging - The logging configuration for your cluster. This parameter is required.
      Returns:
      this
    • logging

      @Stability(Stable) public CfnCluster.Builder logging(CfnCluster.LoggingProperty logging)
      The logging configuration for your cluster.

      Parameters:
      logging - The logging configuration for your cluster. This parameter is required.
      Returns:
      this
    • name

      @Stability(Stable) public CfnCluster.Builder name(String name)
      The unique name to give to your cluster.

      Parameters:
      name - The unique name to give to your cluster. This parameter is required.
      Returns:
      this
    • outpostConfig

      @Stability(Stable) public CfnCluster.Builder outpostConfig(IResolvable outpostConfig)
      An object representing the configuration of your local Amazon EKS cluster on an AWS Outpost.

      This object isn't available for clusters on the AWS cloud.

      Parameters:
      outpostConfig - An object representing the configuration of your local Amazon EKS cluster on an AWS Outpost. This parameter is required.
      Returns:
      this
    • outpostConfig

      @Stability(Stable) public CfnCluster.Builder outpostConfig(CfnCluster.OutpostConfigProperty outpostConfig)
      An object representing the configuration of your local Amazon EKS cluster on an AWS Outpost.

      This object isn't available for clusters on the AWS cloud.

      Parameters:
      outpostConfig - An object representing the configuration of your local Amazon EKS cluster on an AWS Outpost. This parameter is required.
      Returns:
      this
    • tags

      @Stability(Stable) public CfnCluster.Builder tags(List<? extends CfnTag> tags)
      The metadata that you apply to the cluster to assist with categorization and organization.

      Each tag consists of a key and an optional value, both of which you define. Cluster tags don't propagate to any other resources associated with the cluster.

      You must have the eks:TagResource and eks:UntagResource permissions for your IAM principal to manage the AWS CloudFormation stack. If you don't have these permissions, there might be unexpected behavior with stack-level tags propagating to the resource during resource creation and update.

      Parameters:
      tags - The metadata that you apply to the cluster to assist with categorization and organization. This parameter is required.
      Returns:
      this
    • version

      @Stability(Stable) public CfnCluster.Builder version(String version)
      The desired Kubernetes version for your cluster.

      If you don't specify a value here, the default version available in Amazon EKS is used.

      The default version might not be the latest version available.

      Parameters:
      version - The desired Kubernetes version for your cluster. This parameter is required.
      Returns:
      this
    • build

      @Stability(Stable) public CfnCluster build()
      Specified by:
      build in interface software.amazon.jsii.Builder<CfnCluster>
      Returns:
      a newly built instance of CfnCluster.