mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Allow to kill/stop ghosts
This commit is contained in:
parent
d440782e17
commit
f926ed182f
1 changed files with 0 additions and 6 deletions
|
@ -646,9 +646,6 @@ func (container *Container) Kill() error {
|
|||
if !container.State.Running {
|
||||
return nil
|
||||
}
|
||||
if container.State.Ghost {
|
||||
return fmt.Errorf("Can't kill ghost container")
|
||||
}
|
||||
return container.kill()
|
||||
}
|
||||
|
||||
|
@ -658,9 +655,6 @@ func (container *Container) Stop(seconds int) error {
|
|||
if !container.State.Running {
|
||||
return nil
|
||||
}
|
||||
if container.State.Ghost {
|
||||
return fmt.Errorf("Can't stop ghost container")
|
||||
}
|
||||
|
||||
// 1. Send a SIGTERM
|
||||
if output, err := exec.Command("lxc-kill", "-n", container.Id, "15").CombinedOutput(); err != nil {
|
||||
|
|
Loading…
Reference in a new issue