diff --git a/VERSION b/VERSION index 25939d3..20f0687 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.29.1 +0.29.2 diff --git a/modules/vpc/variables.tf b/modules/vpc/variables.tf index daa4a2b..edd39bf 100644 --- a/modules/vpc/variables.tf +++ b/modules/vpc/variables.tf @@ -176,17 +176,23 @@ variable "default_network_acl" { nullable = false validation { - condition = alltrue([ - for rule in try(var.default_network_acl.ingress_rules, []) : - contains(["ALLOW", "DENY"], rule.action) - ]) + condition = (var.default_network_acl.ingress_rules != null + ? alltrue([ + for rule in var.default_network_acl.ingress_rules : + contains(["ALLOW", "DENY"], rule.action) + ]) + : true + ) error_message = "Valid values for `action` of each rules are `ALLOW` and `DENY`." } validation { - condition = alltrue([ - for rule in try(var.default_network_acl.egress_rules, []) : - contains(["ALLOW", "DENY"], rule.action) - ]) + condition = (var.default_network_acl.egress_rules != null + ? alltrue([ + for rule in var.default_network_acl.egress_rules : + contains(["ALLOW", "DENY"], rule.action) + ]) + : true + ) error_message = "Valid values for `action` of each rules are `ALLOW` and `DENY`." } }