forked from Ivasoft/traefik
Filter ECS tasks by LastStatus before adding to list of service tasks
This commit is contained in:
committed by
Traefiker Bot
parent
6aa040ad9f
commit
31b80683c8
@@ -240,7 +240,9 @@ func (p *Provider) listInstances(ctx context.Context, client *awsClient) ([]ecsI
|
||||
log.Errorf("Unable to describe tasks for %v", page.TaskArns)
|
||||
} else {
|
||||
for _, t := range resp.Tasks {
|
||||
tasks[aws.StringValue(t.TaskArn)] = t
|
||||
if aws.StringValue(t.LastStatus) == ecs.DesiredStatusRunning {
|
||||
tasks[aws.StringValue(t.TaskArn)] = t
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user