terraform-aws-eks-node-group icon indicating copy to clipboard operation
terraform-aws-eks-node-group copied to clipboard

Support attribute-based instance type selection

Open Nuru opened this issue 4 years ago • 4 comments

Support attribute-based instance type selection when the AWS Terraform provider supports it. See AWS announcement

Nuru avatar Nov 05 '21 19:11 Nuru

Ticket to track https://github.com/hashicorp/terraform-provider-aws/issues/21566

nitrocode avatar Nov 11 '21 16:11 nitrocode

Ticket to track https://github.com/hashicorp/terraform-provider-aws/issues/21566

This has been closed/released in in AWS Provider v4.16.0

jtdoepke avatar May 31 '22 15:05 jtdoepke

@jtdoepke cool, thanks for the heads up!

Looks like we can use the instance_requirements block on the launch template to make use of this feature.

https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/launch_template#instance-requirements

The aws_launch_template resource says if we use instance_requirements then we cannot use instance_type argument.

We do not use instance_type on the launch template but we do use instance_types on the aws_eks_node_group.

https://github.com/cloudposse/terraform-aws-eks-node-group/blob/0d9d6a21a09f82fc5146859e188e7362686243b6/main.tf#L116

https://github.com/cloudposse/terraform-aws-eks-node-group/blob/0d9d6a21a09f82fc5146859e188e7362686243b6/main.tf#L129

nitrocode avatar Jun 07 '22 13:06 nitrocode

@jtdoepke if you want to test this out, please take a look at the draft PR #120

nitrocode avatar Jun 07 '22 14:06 nitrocode