Documentation ¶
Index ¶
- func AwsAuth_IsConstruct(x interface{}) *bool
- func CfnAddon_CFN_RESOURCE_TYPE_NAME() *string
- func CfnAddon_IsCfnElement(x interface{}) *bool
- func CfnAddon_IsCfnResource(construct constructs.IConstruct) *bool
- func CfnAddon_IsConstruct(x interface{}) *bool
- func CfnCluster_CFN_RESOURCE_TYPE_NAME() *string
- func CfnCluster_IsCfnElement(x interface{}) *bool
- func CfnCluster_IsCfnResource(construct constructs.IConstruct) *bool
- func CfnCluster_IsConstruct(x interface{}) *bool
- func CfnFargateProfile_CFN_RESOURCE_TYPE_NAME() *string
- func CfnFargateProfile_IsCfnElement(x interface{}) *bool
- func CfnFargateProfile_IsCfnResource(construct constructs.IConstruct) *bool
- func CfnFargateProfile_IsConstruct(x interface{}) *bool
- func CfnNodegroup_CFN_RESOURCE_TYPE_NAME() *string
- func CfnNodegroup_IsCfnElement(x interface{}) *bool
- func CfnNodegroup_IsCfnResource(construct constructs.IConstruct) *bool
- func CfnNodegroup_IsConstruct(x interface{}) *bool
- func Cluster_IsConstruct(x interface{}) *bool
- func Cluster_IsResource(construct awscdk.IConstruct) *bool
- func HelmChart_IsConstruct(x interface{}) *bool
- func HelmChart_RESOURCE_TYPE() *string
- func KubernetesResource_IsConstruct(x interface{}) *bool
- func KubernetesResource_RESOURCE_TYPE() *string
- func NewAwsAuth_Override(a AwsAuth, scope awscdk.Construct, id *string, props *AwsAuthProps)
- func NewCfnAddon_Override(c CfnAddon, scope awscdk.Construct, id *string, props *CfnAddonProps)
- func NewCfnCluster_Override(c CfnCluster, scope awscdk.Construct, id *string, props *CfnClusterProps)
- func NewCfnFargateProfile_Override(c CfnFargateProfile, scope awscdk.Construct, id *string, ...)
- func NewCfnNodegroup_Override(c CfnNodegroup, scope awscdk.Construct, id *string, props *CfnNodegroupProps)
- func NewCluster_Override(c Cluster, scope awscdk.Construct, id *string, props *ClusterProps)
- func NewEksOptimizedImage_Override(e EksOptimizedImage, props *EksOptimizedImageProps)
- func NewHelmChart_Override(h HelmChart, scope awscdk.Construct, id *string, props *HelmChartProps)
- func NewKubernetesResource_Override(k KubernetesResource, scope awscdk.Construct, id *string, ...)
- type AutoScalingGroupOptions
- type AwsAuth
- type AwsAuthProps
- type BootstrapOptions
- type CapacityOptions
- type CfnAddon
- type CfnAddonProps
- type CfnCluster
- type CfnClusterProps
- type CfnCluster_ClusterLoggingProperty
- type CfnCluster_EncryptionConfigProperty
- type CfnCluster_KubernetesNetworkConfigProperty
- type CfnCluster_LoggingProperty
- type CfnCluster_LoggingTypeConfigProperty
- type CfnCluster_ResourcesVpcConfigProperty
- type CfnFargateProfile
- type CfnFargateProfileProps
- type CfnFargateProfile_LabelProperty
- type CfnFargateProfile_SelectorProperty
- type CfnNodegroup
- type CfnNodegroupProps
- type CfnNodegroup_LaunchTemplateSpecificationProperty
- type CfnNodegroup_RemoteAccessProperty
- type CfnNodegroup_ScalingConfigProperty
- type CfnNodegroup_TaintProperty
- type CfnNodegroup_UpdateConfigProperty
- type Cluster
- type ClusterAttributes
- type ClusterProps
- type EksOptimizedImage
- type EksOptimizedImageProps
- type HelmChart
- type HelmChartOptions
- type HelmChartProps
- type ICluster
- type KubernetesResource
- type KubernetesResourceProps
- type Mapping
- type NodeType
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AwsAuth_IsConstruct ¶
func AwsAuth_IsConstruct(x interface{}) *bool
Return whether the given object is a Construct. Experimental.
func CfnAddon_CFN_RESOURCE_TYPE_NAME ¶
func CfnAddon_CFN_RESOURCE_TYPE_NAME() *string
func CfnAddon_IsCfnElement ¶
func CfnAddon_IsCfnElement(x interface{}) *bool
Returns `true` if a construct is a stack element (i.e. part of the synthesized cloudformation template).
Uses duck-typing instead of `instanceof` to allow stack elements from different versions of this library to be included in the same stack.
Returns: The construct as a stack element or undefined if it is not a stack element. Experimental.
func CfnAddon_IsCfnResource ¶
func CfnAddon_IsCfnResource(construct constructs.IConstruct) *bool
Check whether the given construct is a CfnResource. Experimental.
func CfnAddon_IsConstruct ¶
func CfnAddon_IsConstruct(x interface{}) *bool
Return whether the given object is a Construct. Experimental.
func CfnCluster_CFN_RESOURCE_TYPE_NAME ¶
func CfnCluster_CFN_RESOURCE_TYPE_NAME() *string
func CfnCluster_IsCfnElement ¶
func CfnCluster_IsCfnElement(x interface{}) *bool
Returns `true` if a construct is a stack element (i.e. part of the synthesized cloudformation template).
Uses duck-typing instead of `instanceof` to allow stack elements from different versions of this library to be included in the same stack.
Returns: The construct as a stack element or undefined if it is not a stack element. Experimental.
func CfnCluster_IsCfnResource ¶
func CfnCluster_IsCfnResource(construct constructs.IConstruct) *bool
Check whether the given construct is a CfnResource. Experimental.
func CfnCluster_IsConstruct ¶
func CfnCluster_IsConstruct(x interface{}) *bool
Return whether the given object is a Construct. Experimental.
func CfnFargateProfile_CFN_RESOURCE_TYPE_NAME ¶
func CfnFargateProfile_CFN_RESOURCE_TYPE_NAME() *string
func CfnFargateProfile_IsCfnElement ¶
func CfnFargateProfile_IsCfnElement(x interface{}) *bool
Returns `true` if a construct is a stack element (i.e. part of the synthesized cloudformation template).
Uses duck-typing instead of `instanceof` to allow stack elements from different versions of this library to be included in the same stack.
Returns: The construct as a stack element or undefined if it is not a stack element. Experimental.
func CfnFargateProfile_IsCfnResource ¶
func CfnFargateProfile_IsCfnResource(construct constructs.IConstruct) *bool
Check whether the given construct is a CfnResource. Experimental.
func CfnFargateProfile_IsConstruct ¶
func CfnFargateProfile_IsConstruct(x interface{}) *bool
Return whether the given object is a Construct. Experimental.
func CfnNodegroup_CFN_RESOURCE_TYPE_NAME ¶
func CfnNodegroup_CFN_RESOURCE_TYPE_NAME() *string
func CfnNodegroup_IsCfnElement ¶
func CfnNodegroup_IsCfnElement(x interface{}) *bool
Returns `true` if a construct is a stack element (i.e. part of the synthesized cloudformation template).
Uses duck-typing instead of `instanceof` to allow stack elements from different versions of this library to be included in the same stack.
Returns: The construct as a stack element or undefined if it is not a stack element. Experimental.
func CfnNodegroup_IsCfnResource ¶
func CfnNodegroup_IsCfnResource(construct constructs.IConstruct) *bool
Check whether the given construct is a CfnResource. Experimental.
func CfnNodegroup_IsConstruct ¶
func CfnNodegroup_IsConstruct(x interface{}) *bool
Return whether the given object is a Construct. Experimental.
func Cluster_IsConstruct ¶
func Cluster_IsConstruct(x interface{}) *bool
Return whether the given object is a Construct. Experimental.
func Cluster_IsResource ¶
func Cluster_IsResource(construct awscdk.IConstruct) *bool
Check whether the given construct is a Resource. Experimental.
func HelmChart_IsConstruct ¶
func HelmChart_IsConstruct(x interface{}) *bool
Return whether the given object is a Construct. Experimental.
func HelmChart_RESOURCE_TYPE ¶
func HelmChart_RESOURCE_TYPE() *string
func KubernetesResource_IsConstruct ¶
func KubernetesResource_IsConstruct(x interface{}) *bool
Return whether the given object is a Construct. Experimental.
func KubernetesResource_RESOURCE_TYPE ¶
func KubernetesResource_RESOURCE_TYPE() *string
func NewAwsAuth_Override ¶
func NewAwsAuth_Override(a AwsAuth, scope awscdk.Construct, id *string, props *AwsAuthProps)
Experimental.
func NewCfnAddon_Override ¶
func NewCfnAddon_Override(c CfnAddon, scope awscdk.Construct, id *string, props *CfnAddonProps)
Create a new `AWS::EKS::Addon`.
func NewCfnCluster_Override ¶
func NewCfnCluster_Override(c CfnCluster, scope awscdk.Construct, id *string, props *CfnClusterProps)
Create a new `AWS::EKS::Cluster`.
func NewCfnFargateProfile_Override ¶
func NewCfnFargateProfile_Override(c CfnFargateProfile, scope awscdk.Construct, id *string, props *CfnFargateProfileProps)
Create a new `AWS::EKS::FargateProfile`.
func NewCfnNodegroup_Override ¶
func NewCfnNodegroup_Override(c CfnNodegroup, scope awscdk.Construct, id *string, props *CfnNodegroupProps)
Create a new `AWS::EKS::Nodegroup`.
func NewCluster_Override ¶
func NewCluster_Override(c Cluster, scope awscdk.Construct, id *string, props *ClusterProps)
Initiates an EKS Cluster with the supplied arguments. Experimental.
func NewEksOptimizedImage_Override ¶
func NewEksOptimizedImage_Override(e EksOptimizedImage, props *EksOptimizedImageProps)
Constructs a new instance of the EcsOptimizedAmi class. Experimental.
func NewHelmChart_Override ¶
func NewHelmChart_Override(h HelmChart, scope awscdk.Construct, id *string, props *HelmChartProps)
Experimental.
func NewKubernetesResource_Override ¶
func NewKubernetesResource_Override(k KubernetesResource, scope awscdk.Construct, id *string, props *KubernetesResourceProps)
Experimental.
Types ¶
type AutoScalingGroupOptions ¶
type AutoScalingGroupOptions struct { // Configures the EC2 user-data script for instances in this autoscaling group to bootstrap the node (invoke `/etc/eks/bootstrap.sh`) and associate it with the EKS cluster. // // If you wish to provide a custom user data script, set this to `false` and // manually invoke `autoscalingGroup.addUserData()`. // Experimental. BootstrapEnabled *bool `json:"bootstrapEnabled"` // Allows options for node bootstrapping through EC2 user data. // Experimental. BootstrapOptions *BootstrapOptions `json:"bootstrapOptions"` // Will automatically update the aws-auth ConfigMap to map the IAM instance role to RBAC. // // This cannot be explicitly set to `true` if the cluster has kubectl disabled. // Experimental. MapRole *bool `json:"mapRole"` }
Options for adding an AutoScalingGroup as capacity.
TODO: EXAMPLE
Experimental.
type AwsAuth ¶
type AwsAuth interface { awscdk.Construct Node() awscdk.ConstructNode AddAccount(accountId *string) AddMastersRole(role awsiam.IRole, username *string) AddRoleMapping(role awsiam.IRole, mapping *Mapping) AddUserMapping(user awsiam.IUser, mapping *Mapping) OnPrepare() OnSynthesize(session constructs.ISynthesisSession) OnValidate() *[]*string Prepare() Synthesize(session awscdk.ISynthesisSession) ToString() *string Validate() *[]*string }
Manages mapping between IAM users and roles to Kubernetes RBAC configuration.
TODO: EXAMPLE
See: https://docs.aws.amazon.com/en_us/eks/latest/userguide/add-user-role.html
Experimental.
func NewAwsAuth ¶
func NewAwsAuth(scope awscdk.Construct, id *string, props *AwsAuthProps) AwsAuth
Experimental.
type AwsAuthProps ¶
type AwsAuthProps struct { // The EKS cluster to apply this configuration to. // // [disable-awslint:ref-via-interface] // Experimental. Cluster Cluster `json:"cluster"` }
TODO: EXAMPLE
Experimental.
type BootstrapOptions ¶
type BootstrapOptions struct { // Additional command line arguments to pass to the `/etc/eks/bootstrap.sh` command. // See: https://github.com/awslabs/amazon-eks-ami/blob/master/files/bootstrap.sh // // Experimental. AdditionalArgs *string `json:"additionalArgs"` // Number of retry attempts for AWS API call (DescribeCluster). // Experimental. AwsApiRetryAttempts *float64 `json:"awsApiRetryAttempts"` // The contents of the `/etc/docker/daemon.json` file. Useful if you want a custom config differing from the default one in the EKS AMI. // Experimental. DockerConfigJson *string `json:"dockerConfigJson"` // Restores the docker default bridge network. // Experimental. EnableDockerBridge *bool `json:"enableDockerBridge"` // Extra arguments to add to the kubelet. Useful for adding labels or taints. // // For example, `--node-labels foo=bar,goo=far` // Experimental. KubeletExtraArgs *string `json:"kubeletExtraArgs"` // Sets `--max-pods` for the kubelet based on the capacity of the EC2 instance. // Experimental. UseMaxPods *bool `json:"useMaxPods"` }
TODO: EXAMPLE
Experimental.
type CapacityOptions ¶
type CapacityOptions struct { // Whether the instances can initiate connections to anywhere by default. // Experimental. AllowAllOutbound *bool `json:"allowAllOutbound"` // Whether instances in the Auto Scaling Group should have public IP addresses associated with them. // Experimental. AssociatePublicIpAddress *bool `json:"associatePublicIpAddress"` // The name of the Auto Scaling group. // // This name must be unique per Region per account. // Experimental. AutoScalingGroupName *string `json:"autoScalingGroupName"` // Specifies how block devices are exposed to the instance. You can specify virtual devices and EBS volumes. // // Each instance that is launched has an associated root device volume, // either an Amazon EBS volume or an instance store volume. // You can use block device mappings to specify additional EBS volumes or // instance store volumes to attach to an instance when it is launched. // See: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/block-device-mapping-concepts.html // // Experimental. BlockDevices *[]*awsautoscaling.BlockDevice `json:"blockDevices"` // Default scaling cooldown for this AutoScalingGroup. // Experimental. Cooldown awscdk.Duration `json:"cooldown"` // Initial amount of instances in the fleet. // // If this is set to a number, every deployment will reset the amount of // instances to this number. It is recommended to leave this value blank. // See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-as-group.html#cfn-as-group-desiredcapacity // // Experimental. DesiredCapacity *float64 `json:"desiredCapacity"` // Enable monitoring for group metrics, these metrics describe the group rather than any of its instances. // // To report all group metrics use `GroupMetrics.all()` // Group metrics are reported in a granularity of 1 minute at no additional charge. // Experimental. GroupMetrics *[]awsautoscaling.GroupMetrics `json:"groupMetrics"` // Configuration for health checks. // Experimental. HealthCheck awsautoscaling.HealthCheck `json:"healthCheck"` // If the ASG has scheduled actions, don't reset unchanged group sizes. // // Only used if the ASG has scheduled actions (which may scale your ASG up // or down regardless of cdk deployments). If true, the size of the group // will only be reset if it has been changed in the CDK app. If false, the // sizes will always be changed back to what they were in the CDK app // on deployment. // Experimental. IgnoreUnmodifiedSizeProperties *bool `json:"ignoreUnmodifiedSizeProperties"` // Controls whether instances in this group are launched with detailed or basic monitoring. // // When detailed monitoring is enabled, Amazon CloudWatch generates metrics every minute and your account // is charged a fee. When you disable detailed monitoring, CloudWatch generates metrics every 5 minutes. // See: https://docs.aws.amazon.com/autoscaling/latest/userguide/as-instance-monitoring.html#enable-as-instance-metrics // // Experimental. InstanceMonitoring awsautoscaling.Monitoring `json:"instanceMonitoring"` // Name of SSH keypair to grant access to instances. // Experimental. KeyName *string `json:"keyName"` // Maximum number of instances in the fleet. // Experimental. MaxCapacity *float64 `json:"maxCapacity"` // The maximum amount of time that an instance can be in service. // // The maximum duration applies // to all current and future instances in the group. As an instance approaches its maximum duration, // it is terminated and replaced, and cannot be used again. // // You must specify a value of at least 604,800 seconds (7 days). To clear a previously set value, // leave this property undefined. // See: https://docs.aws.amazon.com/autoscaling/ec2/userguide/asg-max-instance-lifetime.html // // Experimental. MaxInstanceLifetime awscdk.Duration `json:"maxInstanceLifetime"` // Minimum number of instances in the fleet. // Experimental. MinCapacity *float64 `json:"minCapacity"` // Whether newly-launched instances are protected from termination by Amazon EC2 Auto Scaling when scaling in. // // By default, Auto Scaling can terminate an instance at any time after launch // when scaling in an Auto Scaling Group, subject to the group's termination // policy. However, you may wish to protect newly-launched instances from // being scaled in if they are going to run critical applications that should // not be prematurely terminated. // // This flag must be enabled if the Auto Scaling Group will be associated with // an ECS Capacity Provider with managed termination protection. // Experimental. NewInstancesProtectedFromScaleIn *bool `json:"newInstancesProtectedFromScaleIn"` // Configure autoscaling group to send notifications about fleet changes to an SNS topic(s). // See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-as-group.html#cfn-as-group-notificationconfigurations // // Experimental. Notifications *[]*awsautoscaling.NotificationConfiguration `json:"notifications"` // SNS topic to send notifications about fleet changes. // Deprecated: use `notifications` NotificationsTopic awssns.ITopic `json:"notificationsTopic"` // Configuration for replacing updates. // // Only used if updateType == UpdateType.ReplacingUpdate. Specifies how // many instances must signal success for the update to succeed. // Deprecated: Use `signals` instead ReplacingUpdateMinSuccessfulInstancesPercent *float64 `json:"replacingUpdateMinSuccessfulInstancesPercent"` // How many ResourceSignal calls CloudFormation expects before the resource is considered created. // Deprecated: Use `signals` instead. ResourceSignalCount *float64 `json:"resourceSignalCount"` // The length of time to wait for the resourceSignalCount. // // The maximum value is 43200 (12 hours). // Deprecated: Use `signals` instead. ResourceSignalTimeout awscdk.Duration `json:"resourceSignalTimeout"` // Configuration for rolling updates. // // Only used if updateType == UpdateType.RollingUpdate. // Deprecated: Use `updatePolicy` instead RollingUpdateConfiguration *awsautoscaling.RollingUpdateConfiguration `json:"rollingUpdateConfiguration"` // Configure waiting for signals during deployment. // // Use this to pause the CloudFormation deployment to wait for the instances // in the AutoScalingGroup to report successful startup during // creation and updates. The UserData script needs to invoke `cfn-signal` // with a success or failure code after it is done setting up the instance. // // Without waiting for signals, the CloudFormation deployment will proceed as // soon as the AutoScalingGroup has been created or updated but before the // instances in the group have been started. // // For example, to have instances wait for an Elastic Load Balancing health check before // they signal success, add a health-check verification by using the // cfn-init helper script. For an example, see the verify_instance_health // command in the Auto Scaling rolling updates sample template: // // https://github.com/awslabs/aws-cloudformation-templates/blob/master/aws/services/AutoScaling/AutoScalingRollingUpdates.yaml // Experimental. Signals awsautoscaling.Signals `json:"signals"` // The maximum hourly price (in USD) to be paid for any Spot Instance launched to fulfill the request. // // Spot Instances are // launched when the price you specify exceeds the current Spot market price. // Experimental. SpotPrice *string `json:"spotPrice"` // A policy or a list of policies that are used to select the instances to terminate. // // The policies are executed in the order that you list them. // See: https://docs.aws.amazon.com/autoscaling/ec2/userguide/as-instance-termination.html // // Experimental. TerminationPolicies *[]awsautoscaling.TerminationPolicy `json:"terminationPolicies"` // What to do when an AutoScalingGroup's instance configuration is changed. // // This is applied when any of the settings on the ASG are changed that // affect how the instances should be created (VPC, instance type, startup // scripts, etc.). It indicates how the existing instances should be // replaced with new instances matching the new config. By default, nothing // is done and only new instances are launched with the new config. // Experimental. UpdatePolicy awsautoscaling.UpdatePolicy `json:"updatePolicy"` // What to do when an AutoScalingGroup's instance configuration is changed. // // This is applied when any of the settings on the ASG are changed that // affect how the instances should be created (VPC, instance type, startup // scripts, etc.). It indicates how the existing instances should be // replaced with new instances matching the new config. By default, nothing // is done and only new instances are launched with the new config. // Deprecated: Use `updatePolicy` instead UpdateType awsautoscaling.UpdateType `json:"updateType"` // Where to place instances within the VPC. // Experimental. VpcSubnets *awsec2.SubnetSelection `json:"vpcSubnets"` // Instance type of the instances to start. // Experimental. InstanceType awsec2.InstanceType `json:"instanceType"` // Configures the EC2 user-data script for instances in this autoscaling group to bootstrap the node (invoke `/etc/eks/bootstrap.sh`) and associate it with the EKS cluster. // // If you wish to provide a custom user data script, set this to `false` and // manually invoke `autoscalingGroup.addUserData()`. // Experimental. BootstrapEnabled *bool `json:"bootstrapEnabled"` // EKS node bootstrapping options. // Experimental. BootstrapOptions *BootstrapOptions `json:"bootstrapOptions"` // Will automatically update the aws-auth ConfigMap to map the IAM instance role to RBAC. // // This cannot be explicitly set to `true` if the cluster has kubectl disabled. // Experimental. MapRole *bool `json:"mapRole"` }
Options for adding worker nodes.
TODO: EXAMPLE
Experimental.
type CfnAddon ¶
type CfnAddon interface { awscdk.CfnResource awscdk.IInspectable AddonName() *string SetAddonName(val *string) AddonVersion() *string SetAddonVersion(val *string) AttrArn() *string CfnOptions() awscdk.ICfnResourceOptions CfnProperties() *map[string]interface{} CfnResourceType() *string ClusterName() *string SetClusterName(val *string) CreationStack() *[]*string LogicalId() *string Node() awscdk.ConstructNode Ref() *string ResolveConflicts() *string SetResolveConflicts(val *string) ServiceAccountRoleArn() *string SetServiceAccountRoleArn(val *string) Stack() awscdk.Stack Tags() awscdk.TagManager UpdatedProperites() *map[string]interface{} AddDeletionOverride(path *string) AddDependsOn(target awscdk.CfnResource) AddMetadata(key *string, value interface{}) AddOverride(path *string, value interface{}) AddPropertyDeletionOverride(propertyPath *string) AddPropertyOverride(propertyPath *string, value interface{}) ApplyRemovalPolicy(policy awscdk.RemovalPolicy, options *awscdk.RemovalPolicyOptions) GetAtt(attributeName *string) awscdk.Reference GetMetadata(key *string) interface{} Inspect(inspector awscdk.TreeInspector) OnPrepare() OnSynthesize(session constructs.ISynthesisSession) OnValidate() *[]*string OverrideLogicalId(newLogicalId *string) Prepare() RenderProperties(props *map[string]interface{}) *map[string]interface{} ShouldSynthesize() *bool Synthesize(session awscdk.ISynthesisSession) ToString() *string Validate() *[]*string ValidateProperties(_properties interface{}) }
A CloudFormation `AWS::EKS::Addon`.
Creates an Amazon EKS add-on.
Amazon EKS add-ons help to automate the provisioning and lifecycle management of common operational software for Amazon EKS clusters. Amazon EKS add-ons require clusters running version 1.18 or later because Amazon EKS add-ons rely on the Server-side Apply Kubernetes feature, which is only available in Kubernetes 1.18 and later. For more information, see [Amazon EKS add-ons](https://docs.aws.amazon.com/eks/latest/userguide/eks-add-ons.html) in the *Amazon EKS User Guide* .
TODO: EXAMPLE
func NewCfnAddon ¶
func NewCfnAddon(scope awscdk.Construct, id *string, props *CfnAddonProps) CfnAddon
Create a new `AWS::EKS::Addon`.
type CfnAddonProps ¶
type CfnAddonProps struct { // The name of the add-on. AddonName *string `json:"addonName"` // The name of the cluster. ClusterName *string `json:"clusterName"` // The version of the add-on. AddonVersion *string `json:"addonVersion"` // How to resolve parameter value conflicts when migrating an existing add-on to an Amazon EKS add-on. ResolveConflicts *string `json:"resolveConflicts"` // The Amazon Resource Name (ARN) of an existing IAM role to bind to the add-on's service account. // // The role must be assigned the IAM permissions required by the add-on. If you don't specify an existing IAM role, then the add-on uses the permissions assigned to the node IAM role. For more information, see [Amazon EKS node IAM role](https://docs.aws.amazon.com/eks/latest/userguide/create-node-role.html) in the *Amazon EKS User Guide* . // // > To specify an existing IAM role, you must have an IAM OpenID Connect (OIDC) provider created for your cluster. For more information, see [Enabling IAM roles for service accounts on your cluster](https://docs.aws.amazon.com/eks/latest/userguide/enable-iam-roles-for-service-accounts.html) in the *Amazon EKS User Guide* . ServiceAccountRoleArn *string `json:"serviceAccountRoleArn"` // The metadata that you apply to the add-on to assist with categorization and organization. // // Each tag consists of a key and an optional value, both of which you define. Add-on tags do not propagate to any other resources associated with the cluster. Tags *[]*awscdk.CfnTag `json:"tags"` }
Properties for defining a `CfnAddon`.
TODO: EXAMPLE
type CfnCluster ¶
type CfnCluster interface { awscdk.CfnResource awscdk.IInspectable AttrArn() *string AttrCertificateAuthorityData() *string AttrClusterSecurityGroupId() *string AttrEncryptionConfigKeyArn() *string AttrEndpoint() *string AttrKubernetesNetworkConfigServiceIpv6Cidr() *string AttrOpenIdConnectIssuerUrl() *string CfnOptions() awscdk.ICfnResourceOptions CfnProperties() *map[string]interface{} CfnResourceType() *string CreationStack() *[]*string EncryptionConfig() interface{} SetEncryptionConfig(val interface{}) KubernetesNetworkConfig() interface{} SetKubernetesNetworkConfig(val interface{}) Logging() interface{} SetLogging(val interface{}) LogicalId() *string Name() *string SetName(val *string) Node() awscdk.ConstructNode Ref() *string ResourcesVpcConfig() interface{} SetResourcesVpcConfig(val interface{}) RoleArn() *string SetRoleArn(val *string) Stack() awscdk.Stack Tags() awscdk.TagManager UpdatedProperites() *map[string]interface{} Version() *string SetVersion(val *string) AddDeletionOverride(path *string) AddDependsOn(target awscdk.CfnResource) AddMetadata(key *string, value interface{}) AddOverride(path *string, value interface{}) AddPropertyDeletionOverride(propertyPath *string) AddPropertyOverride(propertyPath *string, value interface{}) ApplyRemovalPolicy(policy awscdk.RemovalPolicy, options *awscdk.RemovalPolicyOptions) GetAtt(attributeName *string) awscdk.Reference GetMetadata(key *string) interface{} Inspect(inspector awscdk.TreeInspector) OnPrepare() OnSynthesize(session constructs.ISynthesisSession) OnValidate() *[]*string OverrideLogicalId(newLogicalId *string) Prepare() RenderProperties(props *map[string]interface{}) *map[string]interface{} ShouldSynthesize() *bool Synthesize(session awscdk.ISynthesisSession) ToString() *string Validate() *[]*string ValidateProperties(_properties interface{}) }
A CloudFormation `AWS::EKS::Cluster`.
Creates an Amazon EKS control plane.
The Amazon EKS control plane consists of control plane instances that run the Kubernetes software, such as `etcd` and the API server. The control plane runs in an account managed by AWS , and the Kubernetes API is exposed by the Amazon EKS API server endpoint. Each Amazon EKS cluster control plane is single tenant and unique. It runs on its own set of Amazon EC2 instances.
The cluster control plane is provisioned across multiple Availability Zones and fronted by an Elastic Load Balancing Network Load Balancer. Amazon EKS also provisions elastic network interfaces in your VPC subnets to provide connectivity from the control plane instances to the nodes (for example, to support `kubectl exec` , `logs` , and `proxy` data flows).
Amazon EKS nodes run in your AWS account and connect to your cluster's control plane over the Kubernetes API server endpoint and a certificate file that is created for your cluster.
In most cases, it takes several minutes to create a cluster. After you create an Amazon EKS cluster, you must configure your Kubernetes tooling to communicate with the API server and launch nodes into your cluster. For more information, see [Managing Cluster Authentication](https://docs.aws.amazon.com/eks/latest/userguide/managing-auth.html) and [Launching Amazon EKS nodes](https://docs.aws.amazon.com/eks/latest/userguide/launch-workers.html) in the *Amazon EKS User Guide* .
TODO: EXAMPLE
func NewCfnCluster ¶
func NewCfnCluster(scope awscdk.Construct, id *string, props *CfnClusterProps) CfnCluster
Create a new `AWS::EKS::Cluster`.
type CfnClusterProps ¶
type CfnClusterProps struct { // 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](https://docs.aws.amazon.com/eks/latest/userguide/network_reqs.html) and [Cluster Security Group Considerations](https://docs.aws.amazon.com/eks/latest/userguide/sec-group-reqs.html) 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. ResourcesVpcConfig interface{} `json:"resourcesVpcConfig"` // 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](https://docs.aws.amazon.com/eks/latest/userguide/service_IAM_role.html) in the **Amazon EKS User Guide** . RoleArn *string `json:"roleArn"` // The encryption configuration for the cluster. EncryptionConfig interface{} `json:"encryptionConfig"` // The Kubernetes network configuration for the cluster. KubernetesNetworkConfig interface{} `json:"kubernetesNetworkConfig"` // The logging configuration for your cluster. Logging interface{} `json:"logging"` // The unique name to give to your cluster. Name *string `json:"name"` // 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 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. Tags *[]*awscdk.CfnTag `json:"tags"` // The desired Kubernetes version for your cluster. // // If you don't specify a value here, the latest version available in Amazon EKS is used. Version *string `json:"version"` }
Properties for defining a `CfnCluster`.
TODO: EXAMPLE
type CfnCluster_ClusterLoggingProperty ¶
type CfnCluster_ClusterLoggingProperty struct { // The enabled control plane logs for your cluster. All log types are disabled if the array is empty. // // > When updating a resource, you must include this `EnabledTypes` property if the previous CloudFormation template of the resource had it. EnabledTypes interface{} `json:"enabledTypes"` }
The cluster control plane logging configuration for your cluster.
> When updating a resource, you must include this `ClusterLogging` property if the previous CloudFormation template of the resource had it.
TODO: EXAMPLE
type CfnCluster_EncryptionConfigProperty ¶
type CfnCluster_EncryptionConfigProperty struct { // The encryption provider for the cluster. Provider interface{} `json:"provider"` // Specifies the resources to be encrypted. // // The only supported value is "secrets". Resources *[]*string `json:"resources"` }
The encryption configuration for the cluster.
TODO: EXAMPLE
type CfnCluster_KubernetesNetworkConfigProperty ¶
type CfnCluster_KubernetesNetworkConfigProperty struct { // `CfnCluster.KubernetesNetworkConfigProperty.IpFamily`. IpFamily *string `json:"ipFamily"` // The CIDR block to assign Kubernetes service IP addresses from. // // If you don't specify a block, Kubernetes assigns addresses from either the 10.100.0.0/16 or 172.20.0.0/16 CIDR blocks. We recommend that you specify a block that does not overlap with resources in other networks that are peered or connected to your VPC. The block must meet the following requirements: // // - Within one of the following private IP address blocks: 10.0.0.0/8, 172.16.0.0/12, or 192.168.0.0/16. // - Doesn't overlap with any CIDR block assigned to the VPC that you selected for VPC. // - Between /24 and /12. // // > You can only specify a custom CIDR block when you create a cluster and can't change this value once the cluster is created. ServiceIpv4Cidr *string `json:"serviceIpv4Cidr"` // `CfnCluster.KubernetesNetworkConfigProperty.ServiceIpv6Cidr`. ServiceIpv6Cidr *string `json:"serviceIpv6Cidr"` }
The Kubernetes network configuration for the cluster.
TODO: EXAMPLE
type CfnCluster_LoggingProperty ¶
type CfnCluster_LoggingProperty struct {
// The cluster control plane logging configuration for your cluster.
ClusterLogging interface{} `json:"clusterLogging"`
}
Enable or disable exporting the Kubernetes control plane logs for your cluster to CloudWatch Logs.
By default, cluster control plane logs aren't exported to CloudWatch Logs. For more information, see [Amazon EKS Cluster control plane logs](https://docs.aws.amazon.com/eks/latest/userguide/control-plane-logs.html) in the **Amazon EKS User Guide** .
> When updating a resource, you must include this `Logging` property if the previous CloudFormation template of the resource had it. > CloudWatch Logs ingestion, archive storage, and data scanning rates apply to exported control plane logs. For more information, see [CloudWatch Pricing](https://docs.aws.amazon.com/cloudwatch/pricing/) .
TODO: EXAMPLE
type CfnCluster_LoggingTypeConfigProperty ¶
type CfnCluster_LoggingTypeConfigProperty struct { // The name of the log type. Type *string `json:"type"` }
The enabled logging type.
For a list of the valid logging types, see the [`types` property of `LogSetup`](https://docs.aws.amazon.com/eks/latest/APIReference/API_LogSetup.html#AmazonEKS-Type-LogSetup-types) in the *Amazon EKS API Reference* .
TODO: EXAMPLE
type CfnCluster_ResourcesVpcConfigProperty ¶
type CfnCluster_ResourcesVpcConfigProperty struct { // Specify subnets for your Amazon EKS nodes. // // Amazon EKS creates cross-account elastic network interfaces in these subnets to allow communication between your nodes and the Kubernetes control plane. SubnetIds *[]*string `json:"subnetIds"` // Set this value to `true` to enable private access for your cluster's Kubernetes API server endpoint. // // If you enable private access, Kubernetes API requests from within your cluster's VPC use the private VPC endpoint. The default value for this parameter is `false` , which disables private access for your Kubernetes API server. If you disable private access and you have nodes or AWS Fargate pods in the cluster, then ensure that `publicAccessCidrs` includes the necessary CIDR blocks for communication with the nodes or Fargate pods. For more information, see [Amazon EKS cluster endpoint access control](https://docs.aws.amazon.com/eks/latest/userguide/cluster-endpoint.html) in the **Amazon EKS User Guide** . EndpointPrivateAccess interface{} `json:"endpointPrivateAccess"` // Set this value to `false` to disable public access to your cluster's Kubernetes API server endpoint. // // If you disable public access, your cluster's Kubernetes API server can only receive requests from within the cluster VPC. The default value for this parameter is `true` , which enables public access for your Kubernetes API server. For more information, see [Amazon EKS cluster endpoint access control](https://docs.aws.amazon.com/eks/latest/userguide/cluster-endpoint.html) in the **Amazon EKS User Guide** . EndpointPublicAccess interface{} `json:"endpointPublicAccess"` // The CIDR blocks that are allowed access to your cluster's public Kubernetes API server endpoint. // // Communication to the endpoint from addresses outside of the CIDR blocks that you specify is denied. The default value is `0.0.0.0/0` . If you've disabled private endpoint access and you have nodes or AWS Fargate pods in the cluster, then ensure that you specify the necessary CIDR blocks. For more information, see [Amazon EKS cluster endpoint access control](https://docs.aws.amazon.com/eks/latest/userguide/cluster-endpoint.html) in the **Amazon EKS User Guide** . PublicAccessCidrs *[]*string `json:"publicAccessCidrs"` // Specify one or more security groups for the cross-account elastic network interfaces that Amazon EKS creates to use that allow communication between your nodes and the Kubernetes control plane. // // If you don't specify any security groups, then familiarize yourself with the difference between Amazon EKS defaults for clusters deployed with Kubernetes: // // - 1.14 Amazon EKS platform version `eks.2` and earlier // - 1.14 Amazon EKS platform version `eks.3` and later // // For more information, see [Amazon EKS security group considerations](https://docs.aws.amazon.com/eks/latest/userguide/sec-group-reqs.html) in the **Amazon EKS User Guide** . SecurityGroupIds *[]*string `json:"securityGroupIds"` }
An object representing the VPC configuration to use for an Amazon EKS cluster.
> When updating a resource, you must include these properties if the previous CloudFormation template of the resource had them: > > - `EndpointPublicAccess` > - `EndpointPrivateAccess` > - `PublicAccessCidrs`
TODO: EXAMPLE
type CfnFargateProfile ¶
type CfnFargateProfile interface { awscdk.CfnResource awscdk.IInspectable AttrArn() *string CfnOptions() awscdk.ICfnResourceOptions CfnProperties() *map[string]interface{} CfnResourceType() *string ClusterName() *string SetClusterName(val *string) CreationStack() *[]*string FargateProfileName() *string SetFargateProfileName(val *string) LogicalId() *string Node() awscdk.ConstructNode PodExecutionRoleArn() *string SetPodExecutionRoleArn(val *string) Ref() *string Selectors() interface{} SetSelectors(val interface{}) Stack() awscdk.Stack Subnets() *[]*string SetSubnets(val *[]*string) Tags() awscdk.TagManager UpdatedProperites() *map[string]interface{} AddDeletionOverride(path *string) AddDependsOn(target awscdk.CfnResource) AddMetadata(key *string, value interface{}) AddOverride(path *string, value interface{}) AddPropertyDeletionOverride(propertyPath *string) AddPropertyOverride(propertyPath *string, value interface{}) ApplyRemovalPolicy(policy awscdk.RemovalPolicy, options *awscdk.RemovalPolicyOptions) GetAtt(attributeName *string) awscdk.Reference GetMetadata(key *string) interface{} Inspect(inspector awscdk.TreeInspector) OnPrepare() OnSynthesize(session constructs.ISynthesisSession) OnValidate() *[]*string OverrideLogicalId(newLogicalId *string) Prepare() RenderProperties(props *map[string]interface{}) *map[string]interface{} ShouldSynthesize() *bool Synthesize(session awscdk.ISynthesisSession) ToString() *string Validate() *[]*string ValidateProperties(_properties interface{}) }
A CloudFormation `AWS::EKS::FargateProfile`.
Creates an AWS Fargate profile for your Amazon EKS cluster. You must have at least one Fargate profile in a cluster to be able to run pods on Fargate.
The Fargate profile allows an administrator to declare which pods run on Fargate and specify which pods run on which Fargate profile. This declaration is done through the profile’s selectors. Each profile can have up to five selectors that contain a namespace and labels. A namespace is required for every selector. The label field consists of multiple optional key-value pairs. Pods that match the selectors are scheduled on Fargate. If a to-be-scheduled pod matches any of the selectors in the Fargate profile, then that pod is run on Fargate.
When you create a Fargate profile, you must specify a pod execution role to use with the pods that are scheduled with the profile. This role is added to the cluster's Kubernetes [Role Based Access Control](https://docs.aws.amazon.com/https://kubernetes.io/docs/admin/authorization/rbac/) (RBAC) for authorization so that the `kubelet` that is running on the Fargate infrastructure can register with your Amazon EKS cluster so that it can appear in your cluster as a node. The pod execution role also provides IAM permissions to the Fargate infrastructure to allow read access to Amazon ECR image repositories. For more information, see [Pod Execution Role](https://docs.aws.amazon.com/eks/latest/userguide/pod-execution-role.html) in the *Amazon EKS User Guide* .
Fargate profiles are immutable. However, you can create a new updated profile to replace an existing profile and then delete the original after the updated profile has finished creating.
If any Fargate profiles in a cluster are in the `DELETING` status, you must wait for that Fargate profile to finish deleting before you can create any other profiles in that cluster.
For more information, see [AWS Fargate Profile](https://docs.aws.amazon.com/eks/latest/userguide/fargate-profile.html) in the *Amazon EKS User Guide* .
TODO: EXAMPLE
func NewCfnFargateProfile ¶
func NewCfnFargateProfile(scope awscdk.Construct, id *string, props *CfnFargateProfileProps) CfnFargateProfile
Create a new `AWS::EKS::FargateProfile`.
type CfnFargateProfileProps ¶
type CfnFargateProfileProps struct { // The name of the Amazon EKS cluster to apply the Fargate profile to. ClusterName *string `json:"clusterName"` // The Amazon Resource Name (ARN) of the pod execution role to use for pods that match the selectors in the Fargate profile. // // The pod execution role allows Fargate infrastructure to register with your cluster as a node, and it provides read access to Amazon ECR image repositories. For more information, see [Pod Execution Role](https://docs.aws.amazon.com/eks/latest/userguide/pod-execution-role.html) in the *Amazon EKS User Guide* . PodExecutionRoleArn *string `json:"podExecutionRoleArn"` // The selectors to match for pods to use this Fargate profile. // // Each selector must have an associated namespace. Optionally, you can also specify labels for a namespace. You may specify up to five selectors in a Fargate profile. Selectors interface{} `json:"selectors"` // The name of the Fargate profile. FargateProfileName *string `json:"fargateProfileName"` // The IDs of subnets to launch your pods into. // // At this time, pods running on Fargate are not assigned public IP addresses, so only private subnets (with no direct route to an Internet Gateway) are accepted for this parameter. Subnets *[]*string `json:"subnets"` // The metadata to apply to the Fargate profile to assist with categorization and organization. // // Each tag consists of a key and an optional value. You define both. Fargate profile tags do not propagate to any other resources associated with the Fargate profile, such as the pods that are scheduled with it. Tags *[]*awscdk.CfnTag `json:"tags"` }
Properties for defining a `CfnFargateProfile`.
TODO: EXAMPLE
type CfnFargateProfile_LabelProperty ¶
type CfnFargateProfile_LabelProperty struct { // Enter a key. Key *string `json:"key"` // Enter a value. Value *string `json:"value"` }
A key-value pair.
TODO: EXAMPLE
type CfnFargateProfile_SelectorProperty ¶
type CfnFargateProfile_SelectorProperty struct { // The Kubernetes namespace that the selector should match. Namespace *string `json:"namespace"` // The Kubernetes labels that the selector should match. // // A pod must contain all of the labels that are specified in the selector for it to be considered a match. Labels interface{} `json:"labels"` }
An object representing an AWS Fargate profile selector.
TODO: EXAMPLE
type CfnNodegroup ¶
type CfnNodegroup interface { awscdk.CfnResource awscdk.IInspectable AmiType() *string SetAmiType(val *string) AttrArn() *string AttrClusterName() *string AttrNodegroupName() *string CapacityType() *string SetCapacityType(val *string) CfnOptions() awscdk.ICfnResourceOptions CfnProperties() *map[string]interface{} CfnResourceType() *string ClusterName() *string SetClusterName(val *string) CreationStack() *[]*string DiskSize() *float64 SetDiskSize(val *float64) ForceUpdateEnabled() interface{} SetForceUpdateEnabled(val interface{}) InstanceTypes() *[]*string SetInstanceTypes(val *[]*string) Labels() interface{} SetLabels(val interface{}) LaunchTemplate() interface{} SetLaunchTemplate(val interface{}) LogicalId() *string Node() awscdk.ConstructNode NodegroupName() *string SetNodegroupName(val *string) NodeRole() *string SetNodeRole(val *string) Ref() *string ReleaseVersion() *string SetReleaseVersion(val *string) RemoteAccess() interface{} SetRemoteAccess(val interface{}) ScalingConfig() interface{} SetScalingConfig(val interface{}) Stack() awscdk.Stack Subnets() *[]*string SetSubnets(val *[]*string) Tags() awscdk.TagManager Taints() interface{} SetTaints(val interface{}) UpdateConfig() interface{} SetUpdateConfig(val interface{}) UpdatedProperites() *map[string]interface{} Version() *string SetVersion(val *string) AddDeletionOverride(path *string) AddDependsOn(target awscdk.CfnResource) AddMetadata(key *string, value interface{}) AddOverride(path *string, value interface{}) AddPropertyDeletionOverride(propertyPath *string) AddPropertyOverride(propertyPath *string, value interface{}) ApplyRemovalPolicy(policy awscdk.RemovalPolicy, options *awscdk.RemovalPolicyOptions) GetAtt(attributeName *string) awscdk.Reference GetMetadata(key *string) interface{} Inspect(inspector awscdk.TreeInspector) OnPrepare() OnSynthesize(session constructs.ISynthesisSession) OnValidate() *[]*string OverrideLogicalId(newLogicalId *string) Prepare() RenderProperties(props *map[string]interface{}) *map[string]interface{} ShouldSynthesize() *bool Synthesize(session awscdk.ISynthesisSession) ToString() *string Validate() *[]*string ValidateProperties(_properties interface{}) }
A CloudFormation `AWS::EKS::Nodegroup`.
Creates a managed node group for an Amazon EKS cluster. You can only create a node group for your cluster that is equal to the current Kubernetes version for the cluster.
An Amazon EKS managed node group is an Amazon EC2 Auto Scaling group and associated Amazon EC2 instances that are managed by AWS for an Amazon EKS cluster. Each node group uses a version of the Amazon EKS optimized Amazon Linux 2 AMI. For more information, see [Managed Node Groups](https://docs.aws.amazon.com/eks/latest/userguide/managed-node-groups.html) in the *Amazon EKS User Guide* .
TODO: EXAMPLE
func NewCfnNodegroup ¶
func NewCfnNodegroup(scope awscdk.Construct, id *string, props *CfnNodegroupProps) CfnNodegroup
Create a new `AWS::EKS::Nodegroup`.
type CfnNodegroupProps ¶
type CfnNodegroupProps struct { // The name of the cluster to create the node group in. ClusterName *string `json:"clusterName"` // The Amazon Resource Name (ARN) of the IAM role to associate with your node group. // // The Amazon EKS worker node `kubelet` daemon makes calls to AWS APIs on your behalf. Nodes receive permissions for these API calls through an IAM instance profile and associated policies. Before you can launch nodes and register them into a cluster, you must create an IAM role for those nodes to use when they are launched. For more information, see [Amazon EKS node IAM role](https://docs.aws.amazon.com/eks/latest/userguide/worker_node_IAM_role.html) in the **Amazon EKS User Guide** . If you specify `launchTemplate` , then don't specify [`IamInstanceProfile`](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_IamInstanceProfile.html) in your launch template, or the node group deployment will fail. For more information about using launch templates with Amazon EKS, see [Launch template support](https://docs.aws.amazon.com/eks/latest/userguide/launch-templates.html) in the *Amazon EKS User Guide* . NodeRole *string `json:"nodeRole"` // The subnets to use for the Auto Scaling group that is created for your node group. // // If you specify `launchTemplate` , then don't specify [`SubnetId`](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateNetworkInterface.html) in your launch template, or the node group deployment will fail. For more information about using launch templates with Amazon EKS, see [Launch template support](https://docs.aws.amazon.com/eks/latest/userguide/launch-templates.html) in the *Amazon EKS User Guide* . Subnets *[]*string `json:"subnets"` // The AMI type for your node group. The following values are examples:. // // - `AL2_x86_64` – Use for Amazon Linux 2 non-GPU instances. // - `AL2_x86_64_GPU` – Use for Amazon Linux 2 GPU instances. // - `AL2_ARM_64` – Use for Amazon Linux 2 Arm instances. // - `CUSTOM` – Use when specifying a custom AMI ID with a launch template. For more information, see [Specifying an AMI](https://docs.aws.amazon.com/eks/latest/userguide/launch-templates.html#launch-template-custom-ami) in the *Amazon EKS User Guide* . // - `BOTTLEROCKET_ARM_64` – Use for Bottlerocket Arm instances. // - `BOTTLEROCKET_x86_64` – Use for Bottlerocket x86_64 instances. // // If you specify `launchTemplate` , and your launch template uses a custom AMI, then don't specify `amiType` , or the node group deployment will fail. For more information about using launch templates with Amazon EKS, see [Launch template support](https://docs.aws.amazon.com/eks/latest/userguide/launch-templates.html) in the *Amazon EKS User Guide* . AmiType *string `json:"amiType"` // The capacity type of your managed node group. CapacityType *string `json:"capacityType"` // The root device disk size (in GiB) for your node group instances. // // The default disk size is 20 GiB. If you specify `launchTemplate` , then don't specify `diskSize` , or the node group deployment will fail. For more information about using launch templates with Amazon EKS, see [Launch template support](https://docs.aws.amazon.com/eks/latest/userguide/launch-templates.html) in the *Amazon EKS User Guide* . DiskSize *float64 `json:"diskSize"` // Force the update if the existing node group's pods are unable to be drained due to a pod disruption budget issue. // // If an update fails because pods could not be drained, you can force the update after it fails to terminate the old node whether or not any pods are running on the node. ForceUpdateEnabled interface{} `json:"forceUpdateEnabled"` // Specify the instance types for a node group. // // If you specify a GPU instance type, be sure to specify `AL2_x86_64_GPU` with the `amiType` parameter. If you specify `launchTemplate` , then you can specify zero or one instance type in your launch template *or* you can specify 0-20 instance types for `instanceTypes` . If however, you specify an instance type in your launch template *and* specify any `instanceTypes` , the node group deployment will fail. If you don't specify an instance type in a launch template or for `instanceTypes` , then `t3.medium` is used, by default. If you specify `Spot` for `capacityType` , then we recommend specifying multiple values for `instanceTypes` . For more information, see [Managed node group capacity types](https://docs.aws.amazon.com/eks/latest/userguide/managed-node-groups.html#managed-node-group-capacity-types) and [Launch template support](https://docs.aws.amazon.com/eks/latest/userguide/launch-templates.html) in the *Amazon EKS User Guide* . InstanceTypes *[]*string `json:"instanceTypes"` // The Kubernetes labels to be applied to the nodes in the node group when they are created. Labels interface{} `json:"labels"` // An object representing a node group's launch template specification. // // If specified, then do not specify `instanceTypes` , `diskSize` , or `remoteAccess` and make sure that the launch template meets the requirements in `launchTemplateSpecification` . LaunchTemplate interface{} `json:"launchTemplate"` // The unique name to give your node group. NodegroupName *string `json:"nodegroupName"` // The AMI version of the Amazon EKS optimized AMI to use with your node group (for example, `1.14.7- *YYYYMMDD*` ). By default, the latest available AMI version for the node group's current Kubernetes version is used. For more information, see [Amazon EKS optimized Linux AMI Versions](https://docs.aws.amazon.com/eks/latest/userguide/eks-linux-ami-versions.html) in the *Amazon EKS User Guide* . // // > Changing this value triggers an update of the node group if one is available. However, only the latest available AMI release version is valid as an input. You cannot roll back to a previous AMI release version. ReleaseVersion *string `json:"releaseVersion"` // The remote access (SSH) configuration to use with your node group. // // If you specify `launchTemplate` , then don't specify `remoteAccess` , or the node group deployment will fail. For more information about using launch templates with Amazon EKS, see [Launch template support](https://docs.aws.amazon.com/eks/latest/userguide/launch-templates.html) in the *Amazon EKS User Guide* . RemoteAccess interface{} `json:"remoteAccess"` // The scaling configuration details for the Auto Scaling group that is created for your node group. ScalingConfig interface{} `json:"scalingConfig"` // The metadata to apply to the node group to assist with categorization and organization. // // Each tag consists of a key and an optional value. You define both. Node group tags do not propagate to any other resources associated with the node group, such as the Amazon EC2 instances or subnets. Tags interface{} `json:"tags"` // The Kubernetes taints to be applied to the nodes in the node group when they are created. // // Effect is one of `No_Schedule` , `Prefer_No_Schedule` , or `No_Execute` . Kubernetes taints can be used together with tolerations to control how workloads are scheduled to your nodes. Taints interface{} `json:"taints"` // The node group update configuration. UpdateConfig interface{} `json:"updateConfig"` // The Kubernetes version to use for your managed nodes. // // By default, the Kubernetes version of the cluster is used, and this is the only accepted specified value. If you specify `launchTemplate` , and your launch template uses a custom AMI, then don't specify `version` , or the node group deployment will fail. For more information about using launch templates with Amazon EKS, see [Launch template support](https://docs.aws.amazon.com/eks/latest/userguide/launch-templates.html) in the *Amazon EKS User Guide* . Version *string `json:"version"` }
Properties for defining a `CfnNodegroup`.
TODO: EXAMPLE
type CfnNodegroup_LaunchTemplateSpecificationProperty ¶
type CfnNodegroup_LaunchTemplateSpecificationProperty struct { // The ID of the launch template. Id *string `json:"id"` // The name of the launch template. Name *string `json:"name"` // The version of the launch template to use. // // If no version is specified, then the template's default version is used. Version *string `json:"version"` }
An object representing a node group launch template specification.
The launch template cannot include [`SubnetId`](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateNetworkInterface.html) , [`IamInstanceProfile`](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_IamInstanceProfile.html) , [`RequestSpotInstances`](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_RequestSpotInstances.html) , [`HibernationOptions`](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_HibernationOptionsRequest.html) , or [`TerminateInstances`](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_TerminateInstances.html) , or the node group deployment or update will fail. For more information about launch templates, see [`CreateLaunchTemplate`](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CreateLaunchTemplate.html) in the Amazon EC2 API Reference. For more information about using launch templates with Amazon EKS, see [Launch template support](https://docs.aws.amazon.com/eks/latest/userguide/launch-templates.html) in the *Amazon EKS User Guide* .
Specify either `name` or `id` , but not both.
TODO: EXAMPLE
type CfnNodegroup_RemoteAccessProperty ¶
type CfnNodegroup_RemoteAccessProperty struct { // The Amazon EC2 SSH key that provides access for SSH communication with the nodes in the managed node group. // // For more information, see [Amazon EC2 key pairs and Linux instances](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-key-pairs.html) in the *Amazon Elastic Compute Cloud User Guide for Linux Instances* . Ec2SshKey *string `json:"ec2SshKey"` // The security groups that are allowed SSH access (port 22) to the nodes. // // If you specify an Amazon EC2 SSH key but do not specify a source security group when you create a managed node group, then port 22 on the nodes is opened to the internet (0.0.0.0/0). For more information, see [Security Groups for Your VPC](https://docs.aws.amazon.com/vpc/latest/userguide/VPC_SecurityGroups.html) in the *Amazon Virtual Private Cloud User Guide* . SourceSecurityGroups *[]*string `json:"sourceSecurityGroups"` }
An object representing the remote access configuration for the managed node group.
TODO: EXAMPLE
type CfnNodegroup_ScalingConfigProperty ¶
type CfnNodegroup_ScalingConfigProperty struct { // The current number of nodes that the managed node group should maintain. // // > If you use Cluster Autoscaler, you shouldn't change the desiredSize value directly, as this can cause the Cluster Autoscaler to suddenly scale up or scale down. // // Whenever this parameter changes, the number of worker nodes in the node group is updated to the specified size. If this parameter is given a value that is smaller than the current number of running worker nodes, the necessary number of worker nodes are terminated to match the given value. When using CloudFormation, no action occurs if you remove this parameter from your CFN template. // // This parameter can be different from minSize in some cases, such as when starting with extra hosts for testing. This parameter can also be different when you want to start with an estimated number of needed hosts, but let Cluster Autoscaler reduce the number if there are too many. When Cluster Autoscaler is used, the desiredSize parameter is altered by Cluster Autoscaler (but can be out-of-date for short periods of time). Cluster Autoscaler doesn't scale a managed node group lower than minSize or higher than maxSize. DesiredSize *float64 `json:"desiredSize"` // The maximum number of nodes that the managed node group can scale out to. // // For information about the maximum number that you can specify, see [Amazon EKS service quotas](https://docs.aws.amazon.com/eks/latest/userguide/service-quotas.html) in the *Amazon EKS User Guide* . MaxSize *float64 `json:"maxSize"` // The minimum number of nodes that the managed node group can scale in to. MinSize *float64 `json:"minSize"` }
An object representing the scaling configuration details for the Auto Scaling group that is associated with your node group.
When creating a node group, you must specify all or none of the properties. When updating a node group, you can specify any or none of the properties.
TODO: EXAMPLE
type CfnNodegroup_TaintProperty ¶
type CfnNodegroup_TaintProperty struct { // The effect of the taint. Effect *string `json:"effect"` // The key of the taint. Key *string `json:"key"` // The value of the taint. Value *string `json:"value"` }
A property that allows a node to repel a set of pods.
TODO: EXAMPLE
type CfnNodegroup_UpdateConfigProperty ¶
type CfnNodegroup_UpdateConfigProperty struct { // // Nodes will be updated in parallel. This value or `maxUnavailablePercentage` is required to have a value.The maximum number is 100. MaxUnavailable *float64 `json:"maxUnavailable"` // // This percentage of nodes will be updated in parallel, up to 100 nodes at once. This value or `maxUnavailable` is required to have a value. MaxUnavailablePercentage *float64 `json:"maxUnavailablePercentage"` }
The update configuration for the node group.
TODO: EXAMPLE
type Cluster ¶
type Cluster interface { awscdk.Resource ICluster AwsAuth() AwsAuth ClusterArn() *string ClusterCertificateAuthorityData() *string ClusterEndpoint() *string ClusterName() *string Connections() awsec2.Connections DefaultCapacity() awsautoscaling.AutoScalingGroup Env() *awscdk.ResourceEnvironment KubectlEnabled() *bool Node() awscdk.ConstructNode PhysicalName() *string Role() awsiam.IRole Stack() awscdk.Stack Vpc() awsec2.IVpc AddAutoScalingGroup(autoScalingGroup awsautoscaling.AutoScalingGroup, options *AutoScalingGroupOptions) AddCapacity(id *string, options *CapacityOptions) awsautoscaling.AutoScalingGroup AddChart(id *string, options *HelmChartOptions) HelmChart AddResource(id *string, manifest ...interface{}) KubernetesResource ApplyRemovalPolicy(policy awscdk.RemovalPolicy) GeneratePhysicalName() *string GetResourceArnAttribute(arnAttr *string, arnComponents *awscdk.ArnComponents) *string GetResourceNameAttribute(nameAttr *string) *string OnPrepare() OnSynthesize(session constructs.ISynthesisSession) OnValidate() *[]*string Prepare() Synthesize(session awscdk.ISynthesisSession) ToString() *string Validate() *[]*string }
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.
TODO: EXAMPLE
Experimental.
func NewCluster ¶
func NewCluster(scope awscdk.Construct, id *string, props *ClusterProps) Cluster
Initiates an EKS Cluster with the supplied arguments. Experimental.
type ClusterAttributes ¶
type ClusterAttributes struct { // The unique ARN assigned to the service by AWS in the form of arn:aws:eks:. // Experimental. ClusterArn *string `json:"clusterArn"` // The certificate-authority-data for your cluster. // Experimental. ClusterCertificateAuthorityData *string `json:"clusterCertificateAuthorityData"` // The API Server endpoint URL. // Experimental. ClusterEndpoint *string `json:"clusterEndpoint"` // The physical name of the Cluster. // Experimental. ClusterName *string `json:"clusterName"` // The security groups associated with this cluster. // Experimental. SecurityGroups *[]awsec2.ISecurityGroup `json:"securityGroups"` // The VPC in which this Cluster was created. // Experimental. Vpc awsec2.IVpc `json:"vpc"` }
TODO: EXAMPLE
Experimental.
type ClusterProps ¶
type ClusterProps struct { // Name for the cluster. // Experimental. ClusterName *string `json:"clusterName"` // Number of instances to allocate as an initial capacity for this cluster. // // Instance type can be configured through `defaultCapacityInstanceType`, // which defaults to `m5.large`. // // Use `cluster.addCapacity` to add additional customized capacity. Set this // to `0` is you wish to avoid the initial capacity allocation. // Experimental. DefaultCapacity *float64 `json:"defaultCapacity"` // The instance type to use for the default capacity. // // This will only be taken // into account if `defaultCapacity` is > 0. // Experimental. DefaultCapacityInstance awsec2.InstanceType `json:"defaultCapacityInstance"` // Allows defining `kubectrl`-related resources on this cluster. // // If this is disabled, it will not be possible to use the following // capabilities: // - `addResource` // - `addRoleMapping` // - `addUserMapping` // - `addMastersRole` and `props.mastersRole` // // If this is disabled, the cluster can only be managed by issuing `kubectl` // commands from a session that uses the IAM role/user that created the // account. // // _NOTE_: changing this value will destoy the cluster. This is because a // managable cluster must be created using an AWS CloudFormation custom // resource which executes with an IAM role owned by the CDK app. // Experimental. KubectlEnabled *bool `json:"kubectlEnabled"` // An IAM role that will be added to the `system:masters` Kubernetes RBAC group. // See: https://kubernetes.io/docs/reference/access-authn-authz/rbac/#default-roles-and-role-bindings // // Experimental. MastersRole awsiam.IRole `json:"mastersRole"` // Determines whether a CloudFormation output with the name of the cluster will be synthesized. // Experimental. OutputClusterName *bool `json:"outputClusterName"` // Determines whether a CloudFormation output with the `aws eks update-kubeconfig` command will be synthesized. // // This command will include // the cluster name and, if applicable, the ARN of the masters IAM role. // Experimental. OutputConfigCommand *bool `json:"outputConfigCommand"` // Determines whether a CloudFormation output with the ARN of the "masters" IAM role will be synthesized (if `mastersRole` is specified). // Experimental. OutputMastersRoleArn *bool `json:"outputMastersRoleArn"` // Role that provides permissions for the Kubernetes control plane to make calls to AWS API operations on your behalf. // Experimental. Role awsiam.IRole `json:"role"` // Security Group to use for Control Plane ENIs. // Experimental. SecurityGroup awsec2.ISecurityGroup `json:"securityGroup"` // The Kubernetes version to run in the cluster. // Experimental. Version *string `json:"version"` // The VPC in which to create the Cluster. // Experimental. Vpc awsec2.IVpc `json:"vpc"` // 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: // // “`ts // const vpcSubnets = [ // { subnetType: ec2.SubnetType.PRIVATE } // ] // “` // Experimental. VpcSubnets *[]*awsec2.SubnetSelection `json:"vpcSubnets"` }
Properties to instantiate the Cluster.
TODO: EXAMPLE
Experimental.
type EksOptimizedImage ¶
type EksOptimizedImage interface { awsec2.IMachineImage GetImage(scope awscdk.Construct) *awsec2.MachineImageConfig }
Construct an Amazon Linux 2 image from the latest EKS Optimized AMI published in SSM.
TODO: EXAMPLE
Experimental.
func NewEksOptimizedImage ¶
func NewEksOptimizedImage(props *EksOptimizedImageProps) EksOptimizedImage
Constructs a new instance of the EcsOptimizedAmi class. Experimental.
type EksOptimizedImageProps ¶
type EksOptimizedImageProps struct { // The Kubernetes version to use. // Experimental. KubernetesVersion *string `json:"kubernetesVersion"` // What instance type to retrieve the image for (standard or GPU-optimized). // Experimental. NodeType NodeType `json:"nodeType"` }
Properties for EksOptimizedImage.
TODO: EXAMPLE
Experimental.
type HelmChart ¶
type HelmChart interface { awscdk.Construct Node() awscdk.ConstructNode OnPrepare() OnSynthesize(session constructs.ISynthesisSession) OnValidate() *[]*string Prepare() Synthesize(session awscdk.ISynthesisSession) ToString() *string Validate() *[]*string }
Represents a helm chart within the Kubernetes system.
Applies/deletes the resources using `kubectl` in sync with the resource.
TODO: EXAMPLE
Experimental.
func NewHelmChart ¶
func NewHelmChart(scope awscdk.Construct, id *string, props *HelmChartProps) HelmChart
Experimental.
type HelmChartOptions ¶
type HelmChartOptions struct { // The name of the chart. // Experimental. Chart *string `json:"chart"` // The Kubernetes namespace scope of the requests. // Experimental. Namespace *string `json:"namespace"` // The name of the release. // Experimental. Release *string `json:"release"` // The repository which contains the chart. // // For example: https://kubernetes-charts.storage.googleapis.com/ // Experimental. Repository *string `json:"repository"` // The values to be used by the chart. // Experimental. Values *map[string]interface{} `json:"values"` // The chart version to install. // Experimental. Version *string `json:"version"` }
Helm Chart options.
TODO: EXAMPLE
Experimental.
type HelmChartProps ¶
type HelmChartProps struct { // The name of the chart. // Experimental. Chart *string `json:"chart"` // The Kubernetes namespace scope of the requests. // Experimental. Namespace *string `json:"namespace"` // The name of the release. // Experimental. Release *string `json:"release"` // The repository which contains the chart. // // For example: https://kubernetes-charts.storage.googleapis.com/ // Experimental. Repository *string `json:"repository"` // The values to be used by the chart. // Experimental. Values *map[string]interface{} `json:"values"` // The chart version to install. // Experimental. Version *string `json:"version"` // The EKS cluster to apply this configuration to. // // [disable-awslint:ref-via-interface] // Experimental. Cluster Cluster `json:"cluster"` }
Helm Chart properties.
TODO: EXAMPLE
Experimental.
type ICluster ¶
type ICluster interface { awsec2.IConnectable awscdk.IResource // The unique ARN assigned to the service by AWS in the form of arn:aws:eks:. // Experimental. ClusterArn() *string // The certificate-authority-data for your cluster. // Experimental. ClusterCertificateAuthorityData() *string // The API Server endpoint URL. // Experimental. ClusterEndpoint() *string // The physical name of the Cluster. // Experimental. ClusterName() *string // The VPC in which this Cluster was created. // Experimental. Vpc() awsec2.IVpc }
An EKS cluster. Experimental.
func Cluster_FromClusterAttributes ¶
func Cluster_FromClusterAttributes(scope awscdk.Construct, id *string, attrs *ClusterAttributes) ICluster
Import an existing cluster. Experimental.
type KubernetesResource ¶
type KubernetesResource interface { awscdk.Construct Node() awscdk.ConstructNode OnPrepare() OnSynthesize(session constructs.ISynthesisSession) OnValidate() *[]*string Prepare() Synthesize(session awscdk.ISynthesisSession) ToString() *string Validate() *[]*string }
Represents a resource within the Kubernetes system.
Alternatively, you can use `cluster.addResource(resource[, resource, ...])` to define resources on this cluster.
Applies/deletes the resources using `kubectl` in sync with the resource.
TODO: EXAMPLE
Experimental.
func NewKubernetesResource ¶
func NewKubernetesResource(scope awscdk.Construct, id *string, props *KubernetesResourceProps) KubernetesResource
Experimental.
type KubernetesResourceProps ¶
type KubernetesResourceProps struct { // The EKS cluster to apply this configuration to. // // [disable-awslint:ref-via-interface] // Experimental. Cluster Cluster `json:"cluster"` // The resource manifest. // // Consists of any number of child resources. // // When the resource is created/updated, this manifest will be applied to the // cluster through `kubectl apply` and when the resource or the stack is // deleted, the manifest will be deleted through `kubectl delete`. // // “` // const manifest = { // apiVersion: 'v1', // kind: 'Pod', // metadata: { name: 'mypod' }, // spec: { // containers: [ { name: 'hello', image: 'paulbouwer/hello-kubernetes:1.5', ports: [ { containerPort: 8080 } ] } ] // } // } // “` // Experimental. Manifest *[]interface{} `json:"manifest"` }
TODO: EXAMPLE
Experimental.
type Mapping ¶
type Mapping struct { // A list of groups within Kubernetes to which the role is mapped. // See: https://kubernetes.io/docs/reference/access-authn-authz/rbac/#default-roles-and-role-bindings // // Experimental. Groups *[]*string `json:"groups"` // The user name within Kubernetes to map to the IAM role. // Experimental. Username *string `json:"username"` }
TODO: EXAMPLE
Experimental.