mirror of
https://github.com/ysoftdevs/terraform-aws-eks.git
synced 2026-03-23 18:01:04 +01:00
fix: Call to lookup() closed too early, breaks sg rule creation in cluster sg if custom source sg is defined. (#2319)
Co-authored-by: Bryant Biggs <bryantbiggs@gmail.com>
This commit is contained in:
13
main.tf
13
main.tf
@@ -191,13 +191,12 @@ resource "aws_security_group_rule" "cluster" {
|
||||
type = each.value.type
|
||||
|
||||
# Optional
|
||||
description = lookup(each.value, "description", null)
|
||||
cidr_blocks = lookup(each.value, "cidr_blocks", null)
|
||||
ipv6_cidr_blocks = lookup(each.value, "ipv6_cidr_blocks", null)
|
||||
prefix_list_ids = lookup(each.value, "prefix_list_ids", [])
|
||||
self = lookup(each.value, "self", null)
|
||||
source_security_group_id = lookup(each.value, "source_security_group_id",
|
||||
lookup(each.value, "source_node_security_group", false)) ? local.node_security_group_id : null
|
||||
description = lookup(each.value, "description", null)
|
||||
cidr_blocks = lookup(each.value, "cidr_blocks", null)
|
||||
ipv6_cidr_blocks = lookup(each.value, "ipv6_cidr_blocks", null)
|
||||
prefix_list_ids = lookup(each.value, "prefix_list_ids", null)
|
||||
self = lookup(each.value, "self", null)
|
||||
source_security_group_id = try(each.value.source_node_security_group, false) ? local.node_security_group_id : lookup(each.value, "source_security_group_id", null)
|
||||
}
|
||||
|
||||
################################################################################
|
||||
|
||||
Reference in New Issue
Block a user