Skip to content
This repository has been archived by the owner on Jan 8, 2024. It is now read-only.

Backport of builtin/aws/ecs: fix listener deletion check into release/0.2.x #1088

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion builtin/aws/ecs/platform.go
Original file line number Diff line number Diff line change
Expand Up @@ -1198,7 +1198,7 @@ func destroyALB(
var tgs []*elbv2.TargetGroupTuple

// If there is only 1 target group, delete the listener
if len(def) == 1 {
if len(def) == 1 && len(def[0].ForwardConfig.TargetGroups) == 1 {
log.Debug("only 1 target group, deleting listener")
_, err = elbsrv.DeleteListener(&elbv2.DeleteListenerInput{
ListenerArn: listener.ListenerArn,
Expand Down