CfnClusterProps

class aws_cdk.aws_eks.CfnClusterProps(*, resources_vpc_config, role_arn, encryption_config=None, kubernetes_network_config=None, logging=None, name=None, tags=None, version=None)

Bases: object

Properties for defining a CfnCluster.

Parameters
  • resources_vpc_config (Union[ResourcesVpcConfigProperty, IResolvable]) – 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. .. epigraph:: Updates require replacement of the SecurityGroupIds and SubnetIds sub-properties.

  • role_arn (str) – 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 .

  • encryption_config (Union[IResolvable, Sequence[Union[IResolvable, EncryptionConfigProperty]], None]) – The encryption configuration for the cluster.

  • kubernetes_network_config (Union[IResolvable, KubernetesNetworkConfigProperty, None]) – The Kubernetes network configuration for the cluster.

  • logging (Union[IResolvable, LoggingProperty, None]) – The logging configuration for your cluster.

  • name (Optional[str]) – The unique name to give to your cluster.

  • tags (Optional[Sequence[CfnTag]]) – 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. .. epigraph:: You must have the eks:TagResource and eks:UntagResource permissions in your IAM user or IAM role used to manage the 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.

  • version (Optional[str]) – The desired Kubernetes version for your cluster. If you don’t specify a value here, the latest version available in Amazon EKS is used.

Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-eks-cluster.html

ExampleMetadata

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
import aws_cdk.aws_eks as eks

# provider: Any

cfn_cluster_props = eks.CfnClusterProps(
    resources_vpc_config=eks.CfnCluster.ResourcesVpcConfigProperty(
        subnet_ids=["subnetIds"],

        # the properties below are optional
        endpoint_private_access=False,
        endpoint_public_access=False,
        public_access_cidrs=["publicAccessCidrs"],
        security_group_ids=["securityGroupIds"]
    ),
    role_arn="roleArn",

    # the properties below are optional
    encryption_config=[eks.CfnCluster.EncryptionConfigProperty(
        provider=provider,
        resources=["resources"]
    )],
    kubernetes_network_config=eks.CfnCluster.KubernetesNetworkConfigProperty(
        ip_family="ipFamily",
        service_ipv4_cidr="serviceIpv4Cidr",
        service_ipv6_cidr="serviceIpv6Cidr"
    ),
    logging=eks.CfnCluster.LoggingProperty(
        cluster_logging=eks.CfnCluster.ClusterLoggingProperty(
            enabled_types=[eks.CfnCluster.LoggingTypeConfigProperty(
                type="type"
            )]
        )
    ),
    name="name",
    tags=[CfnTag(
        key="key",
        value="value"
    )],
    version="version"
)

Attributes

encryption_config

The encryption configuration for the cluster.

Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-eks-cluster.html#cfn-eks-cluster-encryptionconfig

Return type

Union[IResolvable, List[Union[IResolvable, EncryptionConfigProperty]], None]

kubernetes_network_config

The Kubernetes network configuration for the cluster.

Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-eks-cluster.html#cfn-eks-cluster-kubernetesnetworkconfig

Return type

Union[IResolvable, KubernetesNetworkConfigProperty, None]

logging

The logging configuration for your cluster.

Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-eks-cluster.html#cfn-eks-cluster-logging

Return type

Union[IResolvable, LoggingProperty, None]

name

The unique name to give to your cluster.

Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-eks-cluster.html#cfn-eks-cluster-name

Return type

Optional[str]

resources_vpc_config

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. .. epigraph:

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

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-eks-cluster.html#cfn-eks-cluster-resourcesvpcconfig

Return type

Union[ResourcesVpcConfigProperty, IResolvable]

role_arn

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 .

Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-eks-cluster.html#cfn-eks-cluster-rolearn

Return type

str

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. .. epigraph:

You must have the ``eks:TagResource`` and ``eks:UntagResource`` permissions in your IAM user or IAM role used to manage the 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.
Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-eks-cluster.html#cfn-eks-cluster-tags

Return type

Optional[List[CfnTag]]

version

The desired Kubernetes version for your cluster.

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

Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-eks-cluster.html#cfn-eks-cluster-version

Return type

Optional[str]