Fix daemon panic use wrong graphdriver with --live-restore flag
Signed-off-by: Lei Jitang <leijitang@huawei.com>
(cherry picked from commit d9e8cea1b6
)
Signed-off-by: Tibor Vass <tibor@docker.com>
This commit is contained in:
parent
09b01499b7
commit
3d0cd8442e
1 changed files with 1 additions and 1 deletions
|
@ -653,7 +653,7 @@ func (daemon *Daemon) Shutdown() error {
|
|||
daemon.shutdown = true
|
||||
// Keep mounts and networking running on daemon shutdown if
|
||||
// we are to keep containers running and restore them.
|
||||
if daemon.configStore.LiveRestore {
|
||||
if daemon.configStore.LiveRestore && daemon.containers != nil {
|
||||
// check if there are any running containers, if none we should do some cleanup
|
||||
if ls, err := daemon.Containers(&types.ContainerListOptions{}); len(ls) != 0 || err != nil {
|
||||
return nil
|
||||
|
|
Loading…
Reference in a new issue