From d63a86b4b46cc9c378f5f60d157c0be9f9a6539f Mon Sep 17 00:00:00 2001 From: Djordje Lukic Date: Wed, 10 Aug 2022 11:44:01 +0200 Subject: [PATCH] Don't try to restore containers on restart with contaienrd This needs more work to make containerd the source of truth when it's used. It's safer for now to not try and restore any containers. Signed-off-by: Djordje Lukic --- daemon/daemon.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/daemon/daemon.go b/daemon/daemon.go index e59be1edd5b5a..e1c2e50f0f2bc 100644 --- a/daemon/daemon.go +++ b/daemon/daemon.go @@ -204,6 +204,11 @@ func (daemon *Daemon) RegistryHosts() docker.RegistryHosts { } func (daemon *Daemon) restore(ctx context.Context) error { + // Restoring containers after a restart is not yet supported + // when using the containerd content store. + if daemon.UsesSnapshotter() { + return nil + } var mapLock sync.Mutex containers := make(map[string]*container.Container)