mirror of
https://github.com/ysoftdevs/terraform-aws-eks.git
synced 2026-03-17 23:13:46 +01:00
fix: Correct capacity_reservation_target within launch templates of both EKS and self managed node groups (#1979)
This commit is contained in:
@@ -94,7 +94,7 @@ resource "aws_launch_template" "this" {
|
||||
capacity_reservation_preference = lookup(capacity_reservation_specification.value, "capacity_reservation_preference", null)
|
||||
|
||||
dynamic "capacity_reservation_target" {
|
||||
for_each = lookup(capacity_reservation_specification.value, "capacity_reservation_target", [])
|
||||
for_each = try([capacity_reservation_specification.value.capacity_reservation_target], [])
|
||||
content {
|
||||
capacity_reservation_id = lookup(capacity_reservation_target.value, "capacity_reservation_id", null)
|
||||
}
|
||||
|
||||
@@ -97,7 +97,7 @@ resource "aws_launch_template" "this" {
|
||||
capacity_reservation_preference = lookup(capacity_reservation_specification.value, "capacity_reservation_preference", null)
|
||||
|
||||
dynamic "capacity_reservation_target" {
|
||||
for_each = lookup(capacity_reservation_specification.value, "capacity_reservation_target", [])
|
||||
for_each = try([capacity_reservation_specification.value.capacity_reservation_target], [])
|
||||
content {
|
||||
capacity_reservation_id = lookup(capacity_reservation_target.value, "capacity_reservation_id", null)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user