[Feature] diskSize property for root device disk size in ClusterProvider
In case of the CDK v2, NodegroupOptions provides the diskSize property for root device disk size. https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_eks.NodegroupOptions.html#disksize
I could not find the diskSize property in ManagedNodeGroup interface: https://github.com/aws-samples/cdk-eks-blueprints-patterns/blob/main/lib/generic-cluster-construct/index.ts
const clusterProvider = new blueprints.GenericClusterProvider({
version: eks.KubernetesVersion.V1_21,
managedNodeGroups: [
{
id: "mng-ondemand",
amiType: eks.NodegroupAmiType.AL2_X86_64,
instanceTypes: [new ec2.InstanceType('m5.2xlarge')]
},
{
id: "mng2-spot",
instanceTypes: [ec2.InstanceType.of(ec2.InstanceClass.BURSTABLE3, ec2.InstanceSize.MEDIUM)],
nodeGroupCapacityType: eks.CapacityType.SPOT
}
]
});
How can I set the Volume size in blueprints?
Thank you
This will be fixed by exposing the disk size parameter. If there is anything else of similar nature that you would like to add to the node group configuration, please let me know.
This will be fixed by exposing the disk size parameter. If there is anything else of similar nature that you would like to add to the node group configuration, please let me know.
Thank you Mikhail Shapirov As of now, K8s label feature is not yet supported. In case of GPU instance, it's mandatory to use GPU like the following:
const cluster = new eks.Cluster(this, 'eksCluster', {
clusterName: CLUSTER_NAME,
tags: {
Name: CLUSTER_NAME,
},
mastersRole: clusterAdmin,
role: eksRole,
version: eks.KubernetesVersion.V1_21,
vpc: vpc,
defaultCapacity: 2,
defaultCapacityInstance: new ec2.InstanceType('c5.large'),
clusterLogging: [
eks.ClusterLoggingTypes.API,
eks.ClusterLoggingTypes.SCHEDULER
],
});
const gpuNodeGroup = cluster.addNodegroupCapacity('gpuNg', {
nodegroupName: 'gpu-ng',
instanceTypes: [new ec2.InstanceType('p2.xlarge')],
labels: { 'accelerator': 'nvidia-gpu' }, <- like this
minSize: 2,
maxSize: 10,
capacityType: eks.CapacityType.SPOT
});
Please add a function or property for labels as well.
@engel80 this has been supported for a couple of patch releases. You can use labels like this:
const clusterProvider = new blueprints.GenericClusterProvider({
version: KubernetesVersion.V1_21,
managedNodeGroups: [
{
id: "mng1",
amiType: NodegroupAmiType.AL2_X86_64,
instanceTypes: [new ec2.InstanceType('m5.2xlarge')],
diskSize: 25,
nodeGroupSubnets: { subnetType: ec2.SubnetType.PRIVATE_WITH_NAT },
labels: {
"key": "value"
}
}
Please verify if you get a chance.
This issue has been automatically marked as stale because it has been open 60 days with no activity. Remove stale label or comment or this issue will be closed in 10 days
Issue closed due to inactivity.