Skip to content

Commit dd507bd

Browse files
committed
Revert "runtime_vm: Cleanup process when the Container is Stopped"
This reverts commit 67dcd05. We cannot simply delete the container when its status changes to stopped. The intention of this fix is okay-ish, but implemented in the wrong layer. What containerd does is calling Shutdown(), when the *pod* is finished, and that's what we should do as well. Signed-off-by: Fabiano Fidêncio <[email protected]>
1 parent 7f0085b commit dd507bd

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

internal/oci/runtime_vm.go

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -276,12 +276,6 @@ func (r *runtimeVM) StartContainer(c *Container) error {
276276
if err1 := r.updateContainerStatus(c); err1 != nil {
277277
logrus.Warningf("error updating container status %v", err1)
278278
}
279-
280-
if c.state.Status == ContainerStateStopped {
281-
if err1 := r.deleteContainer(c, true); err1 != nil {
282-
logrus.WithError(err1).Infof("deleteContainer failed for container %s", c.ID())
283-
}
284-
}
285279
}
286280
}()
287281

0 commit comments

Comments
 (0)