feat: Add the SPOT support for Managed Node Groups (#1129)

BREAKING CHANGES: To add add SPOT support for MNG, the `instance_type` is now a list and renamed as `instance_types`. This will probably rebuild existing Managed Node Groups.
This commit is contained in:
Jonathan Cole
2021-01-28 14:08:29 -08:00
committed by GitHub
parent 76537d1b8d
commit 8978997bb1
5 changed files with 11 additions and 5 deletions

View File

@@ -15,8 +15,9 @@ resource "aws_eks_node_group" "workers" {
ami_type = lookup(each.value, "ami_type", null)
disk_size = lookup(each.value, "disk_size", null)
instance_types = each.value["launch_template_id"] != null ? [] : [each.value["instance_type"]]
instance_types = lookup(each.value, "instance_types", null)
release_version = lookup(each.value, "ami_release_version", null)
capacity_type = lookup(each.value, "capacity_type", null)
dynamic "remote_access" {
for_each = each.value["key_name"] != "" ? [{