java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.core.Construct
software.amazon.awscdk.core.Resource
software.amazon.awscdk.services.eks.legacy.Cluster
All Implemented Interfaces:
IConstruct, IDependable, IResource, IConnectable, ICluster, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct

@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)", date="2023-06-19T16:30:46.768Z") @Stability(Deprecated) @Deprecated public class Cluster extends Resource implements ICluster
Deprecated.
(deprecated) A Cluster represents a managed Kubernetes Service (EKS).

This is a fully managed cluster of API Servers (control-plane) The user is still required to create the worker nodes.

Example:

 Cluster cluster;
 // option 1: use a construct
 // option 1: use a construct
 HelmChart.Builder.create(this, "NginxIngress")
         .cluster(cluster)
         .chart("nginx-ingress")
         .repository("https://helm.nginx.com/stable")
         .namespace("kube-system")
         .build();
 // or, option2: use `addChart`
 cluster.addChart("NginxIngress", HelmChartOptions.builder()
         .chart("nginx-ingress")
         .repository("https://helm.nginx.com/stable")
         .namespace("kube-system")
         .build());
 
  • Constructor Details

    • Cluster

      protected Cluster(software.amazon.jsii.JsiiObjectRef objRef)
      Deprecated.
    • Cluster

      protected Cluster(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
      Deprecated.
    • Cluster

      @Stability(Deprecated) @Deprecated public Cluster(@NotNull Construct scope, @NotNull String id, @Nullable ClusterProps props)
      Deprecated.
      (deprecated) Initiates an EKS Cluster with the supplied arguments.

      Parameters:
      scope - a Construct, most likely a cdk.Stack created. This parameter is required.
      id - This parameter is required.
      props - properties in the IClusterProps interface.
    • Cluster

      @Stability(Deprecated) @Deprecated public Cluster(@NotNull Construct scope, @NotNull String id)
      Deprecated.
      (deprecated) Initiates an EKS Cluster with the supplied arguments.

      Parameters:
      scope - a Construct, most likely a cdk.Stack created. This parameter is required.
      id - This parameter is required.
  • Method Details

    • fromClusterAttributes

      @Stability(Deprecated) @Deprecated @NotNull public static ICluster fromClusterAttributes(@NotNull Construct scope, @NotNull String id, @NotNull ClusterAttributes attrs)
      Deprecated.
      (deprecated) Import an existing cluster.

      Parameters:
      scope - the construct scope, in most cases 'this'. This parameter is required.
      id - the id or name to import as. This parameter is required.
      attrs - the cluster properties to use for importing information. This parameter is required.
    • addAutoScalingGroup

      @Stability(Deprecated) @Deprecated public void addAutoScalingGroup(@NotNull AutoScalingGroup autoScalingGroup, @NotNull AutoScalingGroupOptions options)
      Deprecated.
      (deprecated) Add compute capacity to this EKS cluster in the form of an AutoScalingGroup.

      The AutoScalingGroup must be running an EKS-optimized AMI containing the /etc/eks/bootstrap.sh script. This method will configure Security Groups, add the right policies to the instance role, apply the right tags, and add the required user data to the instance's launch configuration.

      Spot instances will be labeled lifecycle=Ec2Spot and tainted with PreferNoSchedule. If kubectl is enabled, the spot interrupt handler daemon will be installed on all spot instances to handle EC2 Spot Instance Termination Notices.

      Prefer to use addCapacity if possible.

      Parameters:
      autoScalingGroup - [disable-awslint:ref-via-interface]. This parameter is required.
      options - options for adding auto scaling groups, like customizing the bootstrap script. This parameter is required.
      See Also:
    • addCapacity

      @Stability(Deprecated) @Deprecated @NotNull public AutoScalingGroup addCapacity(@NotNull String id, @NotNull CapacityOptions options)
      Deprecated.
      (deprecated) Add nodes to this EKS cluster.

      The nodes will automatically be configured with the right VPC and AMI for the instance type and Kubernetes version.

      Spot instances will be labeled lifecycle=Ec2Spot and tainted with PreferNoSchedule. If kubectl is enabled, the spot interrupt handler daemon will be installed on all spot instances to handle EC2 Spot Instance Termination Notices.

      Parameters:
      id - This parameter is required.
      options - This parameter is required.
    • addChart

      @Stability(Deprecated) @Deprecated @NotNull public HelmChart addChart(@NotNull String id, @NotNull HelmChartOptions options)
      Deprecated.
      (deprecated) Defines a Helm chart in this cluster.

      Parameters:
      id - logical id of this chart. This parameter is required.
      options - options of this chart. This parameter is required.
      Returns:
      a HelmChart object
    • addResource

      @Stability(Deprecated) @Deprecated @NotNull public KubernetesResource addResource(@NotNull String id, @NotNull @NotNull Object... manifest)
      Deprecated.
      (deprecated) Defines a Kubernetes resource in this cluster.

      The manifest will be applied/deleted using kubectl as needed.

      Parameters:
      id - logical id of this manifest. This parameter is required.
      manifest - a list of Kubernetes resource specifications. This parameter is required.
      Returns:
      a KubernetesResource object.
    • getAwsAuth

      @Stability(Deprecated) @Deprecated @NotNull public AwsAuth getAwsAuth()
      Deprecated.
      (deprecated) Lazily creates the AwsAuth resource, which manages AWS authentication mapping.
    • getClusterArn

      @Stability(Deprecated) @Deprecated @NotNull public String getClusterArn()
      Deprecated.
      (deprecated) The AWS generated ARN for the Cluster resource.

      For example, arn:aws:eks:us-west-2:666666666666:cluster/prod

      Specified by:
      getClusterArn in interface ICluster
    • getClusterCertificateAuthorityData

      @Stability(Deprecated) @Deprecated @NotNull public String getClusterCertificateAuthorityData()
      Deprecated.
      (deprecated) The certificate-authority-data for your cluster.
      Specified by:
      getClusterCertificateAuthorityData in interface ICluster
    • getClusterEndpoint

      @Stability(Deprecated) @Deprecated @NotNull public String getClusterEndpoint()
      Deprecated.
      (deprecated) The endpoint URL for the Cluster.

      This is the URL inside the kubeconfig file to use with kubectl

      For example, https://5E1D0CEXAMPLEA591B746AFC5AB30262.yl4.us-west-2.eks.amazonaws.com

      Specified by:
      getClusterEndpoint in interface ICluster
    • getClusterName

      @Stability(Deprecated) @Deprecated @NotNull public String getClusterName()
      Deprecated.
      (deprecated) The Name of the created EKS Cluster.
      Specified by:
      getClusterName in interface ICluster
    • getConnections

      @Stability(Deprecated) @Deprecated @NotNull public Connections getConnections()
      Deprecated.
      (deprecated) Manages connection rules (Security Group Rules) for the cluster.
      Specified by:
      getConnections in interface IConnectable
    • getKubectlEnabled

      @Stability(Deprecated) @Deprecated @NotNull public Boolean getKubectlEnabled()
      Deprecated.
      (deprecated) Indicates if kubectl related operations can be performed on this cluster.
    • getRole

      @Stability(Deprecated) @Deprecated @NotNull public IRole getRole()
      Deprecated.
      (deprecated) IAM role assumed by the EKS Control Plane.
    • getVpc

      @Stability(Deprecated) @Deprecated @NotNull public IVpc getVpc()
      Deprecated.
      (deprecated) The VPC in which this Cluster was created.
      Specified by:
      getVpc in interface ICluster
    • getDefaultCapacity

      @Stability(Deprecated) @Deprecated @Nullable public AutoScalingGroup getDefaultCapacity()
      Deprecated.
      (deprecated) The auto scaling group that hosts the default capacity for this cluster.

      This will be undefined if the default capacity is set to 0.