Skip to content

Commit dd54ede

Browse files
authored
Merge pull request #10 from Faire/aodan.xin/add_engress_rules_to_allowed_cird
Support stateless egress rules to allowed CIDRs
2 parents 6b1b869 + 92794ab commit dd54ede

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

modules/network/nsg-controlplane.tf

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,11 @@ locals {
8282
protocol = local.tcp_protocol, port = local.apiserver_port, source = allowed_cidr, source_type = local.rule_type_cidr
8383
}
8484
},
85+
{ for allowed_cidr in var.control_plane_allowed_cidrs :
86+
"Allow TCP egress from kube-apiserver to ${allowed_cidr}" => {
87+
protocol = local.tcp_protocol, port = local.apiserver_port, destination = allowed_cidr, destination_type = local.rule_type_cidr
88+
}
89+
}, // Allow egress to allowed CIDRs. This could be removed once https://github.com/oracle-terraform-modules/terraform-oci-oke/pull/1044/files#diff-22581a25add62ab66a7fea3ec452a13a8be27d31e3b467ae2b6c1230b9d77a10R158-R162 is merged.
8590
var.allow_rules_cp
8691
) : {}
8792
}

0 commit comments

Comments
 (0)