mirror of
https://github.com/docker/compose.git
synced 2025-07-03 11:54:27 +02:00
When running compose down, remove containers with Force=true in case some container is still up for any reason (happened in some E2E test once)
Signed-off-by: Guillaume Tardif <guillaume.tardif@gmail.com>
This commit is contained in:
parent
df4fed266b
commit
0a5328748a
@ -101,7 +101,7 @@ func (s *composeService) removeContainers(ctx context.Context, w progress.Writer
|
|||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
w.Event(progress.RemovingEvent(eventName))
|
w.Event(progress.RemovingEvent(eventName))
|
||||||
err = s.apiClient.ContainerRemove(ctx, toDelete.ID, moby.ContainerRemoveOptions{})
|
err = s.apiClient.ContainerRemove(ctx, toDelete.ID, moby.ContainerRemoveOptions{Force: true})
|
||||||
if err != nil {
|
if err != nil {
|
||||||
w.Event(progress.ErrorMessageEvent(eventName, "Error while Removing"))
|
w.Event(progress.ErrorMessageEvent(eventName, "Error while Removing"))
|
||||||
return err
|
return err
|
||||||
|
Loading…
x
Reference in New Issue
Block a user