mirror of
https://github.com/containers/podman.git
synced 2025-06-20 17:13:43 +08:00
Remove containers when pruning a stopped pod.
This path allows pod prune & pod rm to remove stopped containers in the pod before deleting the pod. PrunePods and RemovePod should be able to remove containers without force removal of stopped pods. Signed-off-by: Qi Wang <qiwan@redhat.com>
This commit is contained in:
@ -247,7 +247,7 @@ func (i *LibpodAPI) RemovePod(call iopodman.VarlinkCall, name string, force bool
|
||||
if err != nil {
|
||||
return call.ReplyPodNotFound(name, err.Error())
|
||||
}
|
||||
if err = i.Runtime.RemovePod(ctx, pod, force, force); err != nil {
|
||||
if err = i.Runtime.RemovePod(ctx, pod, true, force); err != nil {
|
||||
return call.ReplyErrorOccurred(err.Error())
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user