Skip to content

Commit d086afc

Browse files
committed
Put frontend in private subnet. Now only load balancer is in public subnet.
1 parent 5769377 commit d086afc

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

terraform/modules/ecs/main.tf

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ resource "aws_ecs_service" "frontend" {
9898
launch_type = "FARGATE"
9999

100100
network_configuration {
101-
subnets = var.public_subnet_ids
101+
subnets = var.private_subnet_ids
102102
security_groups = [var.frontend_sg_id, var.alb_sg_id]
103103
assign_public_ip = true
104104
}
@@ -131,10 +131,6 @@ resource "aws_ecs_service" "backend" {
131131
container_port = 3000
132132
}
133133

134-
# service_registries {
135-
# registry_arn = var.backend_service_arn
136-
# }
137-
138134
enable_execute_command = true
139135
}
140136

0 commit comments

Comments
 (0)