Skip to content

How do I enable multiple ecs services to use the same loadbalancer #757

Answered by Etiene
sewmiuraj asked this question in How do I
Discussion options

You must be logged in to vote

Hi @sewmiuraj, each service created by the ecs-service module creates a target_group for an alb, but not an alb. You can connect those two using a listener such as creating a new aws_lb_listener, or you can try using the listener map from the output of the of our alb module as the input for the variable default_listener_arns like below:

https://github.com/gruntwork-io/terraform-aws-service-catalog/blob/c7b283053fcc46d752ff506f335e67f8311ad211/examples/for-production/infrastructure-live/_envcommon/services/ecs-sample-app-frontend.hcl#L135

https://github.com/gruntwork-io/terraform-aws-service-catalog/blob/c7b283053fcc46d752ff506f335e67f8311ad211/examples/for-production/infrastructure-live/_…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by sewmiuraj
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2 participants