Skip to content

Commit

Permalink
Update lb redshfit egress rule.
Browse files Browse the repository at this point in the history
  • Loading branch information
gwionap committed Sep 15, 2023
1 parent 727decb commit c9cf820
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions terraform/environments/data-and-insights-wepi/redshift.tf
Original file line number Diff line number Diff line change
Expand Up @@ -163,10 +163,10 @@ resource "aws_security_group_rule" "lb_tcp_5439_ingress_vpc" {
}

resource "aws_security_group_rule" "lb_tcp_5439_egress_redshift" {
for_each = toset([for node in aws_redshift_cluster.wepi_redshift_cluster.cluster_nodes : node.private_ip_address])
from_port = 5439
prefix_list_ids = [data.aws_vpc_endpoint.redshift.prefix_list_id]
protocol = "TCP"
security_group_id = aws_security_group.redshift-data-lb.id
cidr_blocks = [format("%s/32", each.value)]
to_port = 5439
type = "egress"
}
Expand Down

0 comments on commit c9cf820

Please sign in to comment.