Skip to content

Commit

Permalink
FIX: Missing index from conditional resource
Browse files Browse the repository at this point in the history
  • Loading branch information
Sumit Sarkar committed Jul 4, 2019
1 parent d5b4590 commit b623597
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ resource "aws_ecs_service" "main" {
}

load_balancer {
target_group_arn = var.alb_target_group_id_override == "" ? aws_alb_target_group.main.id : var.alb_target_group_id_override
target_group_arn = var.alb_target_group_id_override == "" ? aws_alb_target_group.main[0].id : var.alb_target_group_id_override
container_name = var.container_name
container_port = var.port
}
Expand Down Expand Up @@ -72,7 +72,7 @@ resource "aws_alb_listener_rule" "attach_listener" {
priority = var.rule_priority

action {
target_group_arn = aws_alb_target_group.main.arn
target_group_arn = aws_alb_target_group.main[0].arn
type = "forward"
}

Expand Down

0 comments on commit b623597

Please sign in to comment.