Fix factory rules key in net firewall policy module (#1587)
* fix factory rules key in net firewall policy * fix test
This commit is contained in:
parent
ad1d5a7ddc
commit
841459a059
|
@ -25,7 +25,7 @@ locals {
|
||||||
yamldecode(file(var.rules_factory_config.cidr_file_path)), {}
|
yamldecode(file(var.rules_factory_config.cidr_file_path)), {}
|
||||||
)
|
)
|
||||||
factory_egress_rules = {
|
factory_egress_rules = {
|
||||||
for k, v in local._factory_egress_rules : "ingress/${k}" => {
|
for k, v in local._factory_egress_rules : "egress/${k}" => {
|
||||||
action = "deny"
|
action = "deny"
|
||||||
direction = "EGRESS"
|
direction = "EGRESS"
|
||||||
priority = v.priority
|
priority = v.priority
|
||||||
|
@ -68,7 +68,7 @@ locals {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
factory_ingress_rules = {
|
factory_ingress_rules = {
|
||||||
for k, v in local._factory_ingress_rules : "egress/${k}" => {
|
for k, v in local._factory_ingress_rules : "ingress/${k}" => {
|
||||||
action = "allow"
|
action = "allow"
|
||||||
direction = "INGRESS"
|
direction = "INGRESS"
|
||||||
priority = v.priority
|
priority = v.priority
|
||||||
|
|
|
@ -18,7 +18,7 @@ values:
|
||||||
module.firewall-policy.google_compute_firewall_policy_association.hierarchical["test"]:
|
module.firewall-policy.google_compute_firewall_policy_association.hierarchical["test"]:
|
||||||
attachment_target: folders/4567890123
|
attachment_target: folders/4567890123
|
||||||
name: test-1-test
|
name: test-1-test
|
||||||
module.firewall-policy.google_compute_firewall_policy_rule.hierarchical["egress/icmp"]:
|
module.firewall-policy.google_compute_firewall_policy_rule.hierarchical["ingress/icmp"]:
|
||||||
action: allow
|
action: allow
|
||||||
direction: INGRESS
|
direction: INGRESS
|
||||||
disabled: false
|
disabled: false
|
||||||
|
@ -41,7 +41,7 @@ values:
|
||||||
priority: 1000
|
priority: 1000
|
||||||
target_resources: null
|
target_resources: null
|
||||||
target_service_accounts: null
|
target_service_accounts: null
|
||||||
module.firewall-policy.google_compute_firewall_policy_rule.hierarchical["ingress/smtp"]:
|
module.firewall-policy.google_compute_firewall_policy_rule.hierarchical["egress/smtp"]:
|
||||||
action: deny
|
action: deny
|
||||||
direction: EGRESS
|
direction: EGRESS
|
||||||
disabled: false
|
disabled: false
|
||||||
|
|
Loading…
Reference in New Issue