@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:38.956Z") @Stability(value=Stable) public class Nodegroup extends Resource implements INodegroup
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.ec2.*;
import software.amazon.awscdk.services.eks.*;
import software.amazon.awscdk.services.iam.*;
Cluster cluster;
InstanceType instanceType;
Role role;
SecurityGroup securityGroup;
Subnet subnet;
SubnetFilter subnetFilter;
Nodegroup nodegroup = Nodegroup.Builder.create(this, "MyNodegroup")
.cluster(cluster)
// the properties below are optional
.amiType(NodegroupAmiType.AL2_X86_64)
.capacityType(CapacityType.SPOT)
.desiredSize(123)
.diskSize(123)
.forceUpdate(false)
.instanceTypes(List.of(instanceType))
.labels(Map.of(
"labelsKey", "labels"))
.launchTemplateSpec(LaunchTemplateSpec.builder()
.id("id")
// the properties below are optional
.version("version")
.build())
.maxSize(123)
.minSize(123)
.nodegroupName("nodegroupName")
.nodeRole(role)
.releaseVersion("releaseVersion")
.remoteAccess(NodegroupRemoteAccess.builder()
.sshKeyName("sshKeyName")
// the properties below are optional
.sourceSecurityGroups(List.of(securityGroup))
.build())
.subnets(SubnetSelection.builder()
.availabilityZones(List.of("availabilityZones"))
.onePerAz(false)
.subnetFilters(List.of(subnetFilter))
.subnetGroupName("subnetGroupName")
.subnets(List.of(subnet))
.subnetType(SubnetType.PRIVATE_ISOLATED)
.build())
.tags(Map.of(
"tagsKey", "tags"))
.taints(List.of(TaintSpec.builder()
.effect(TaintEffect.NO_SCHEDULE)
.key("key")
.value("value")
.build()))
.build();
| Modifier and Type | Class and Description |
|---|---|
static class |
Nodegroup.Builder
A fluent builder for
Nodegroup. |
software.amazon.jsii.JsiiObject.InitializationModeINodegroup.Jsii$Default, INodegroup.Jsii$Proxy| Modifier | Constructor and Description |
|---|---|
|
Nodegroup(software.constructs.Construct scope,
String id,
NodegroupProps props) |
protected |
Nodegroup(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
Nodegroup(software.amazon.jsii.JsiiObjectRef objRef) |
| Modifier and Type | Method and Description |
|---|---|
static INodegroup |
fromNodegroupName(software.constructs.Construct scope,
String id,
String nodegroupName)
Import the Nodegroup from attributes.
|
ICluster |
getCluster()
the Amazon EKS cluster resource.
|
String |
getNodegroupArn()
ARN of the nodegroup.
|
String |
getNodegroupName()
Nodegroup name.
|
IRole |
getRole()
IAM role of the instance profile for the nodegroup.
|
applyRemovalPolicy, generatePhysicalName, getEnv, getPhysicalName, getResourceArnAttribute, getResourceNameAttribute, getStack, isOwnedResource, isResourcejsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitapplyRemovalPolicy, getEnv, getStackprotected Nodegroup(software.amazon.jsii.JsiiObjectRef objRef)
protected Nodegroup(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Stable)
public Nodegroup(@NotNull
software.constructs.Construct scope,
@NotNull
String id,
@NotNull
NodegroupProps props)
scope - This parameter is required.id - This parameter is required.props - This parameter is required.@Stability(value=Stable) @NotNull public static INodegroup fromNodegroupName(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String nodegroupName)
scope - This parameter is required.id - This parameter is required.nodegroupName - This parameter is required.@Stability(value=Stable) @NotNull public ICluster getCluster()
@Stability(value=Stable) @NotNull public String getNodegroupArn()
@Stability(value=Stable) @NotNull public String getNodegroupName()
getNodegroupName in interface INodegroup@Stability(value=Stable) @NotNull public IRole getRole()
Copyright © 2022. All rights reserved.