summaryrefslogtreecommitdiff
path: root/libpod/runtime_migrate.go
diff options
context:
space:
mode:
Diffstat (limited to 'libpod/runtime_migrate.go')
-rw-r--r--libpod/runtime_migrate.go5
1 files changed, 3 insertions, 2 deletions
diff --git a/libpod/runtime_migrate.go b/libpod/runtime_migrate.go
index a084df289..0bb8e952f 100644
--- a/libpod/runtime_migrate.go
+++ b/libpod/runtime_migrate.go
@@ -1,13 +1,14 @@
package libpod
import (
+ "context"
"path/filepath"
"github.com/pkg/errors"
"github.com/sirupsen/logrus"
)
-func (r *Runtime) migrate() error {
+func (r *Runtime) migrate(ctx context.Context) error {
runningContainers, err := r.GetRunningContainers()
if err != nil {
return err
@@ -38,7 +39,7 @@ func (r *Runtime) migrate() error {
}
for _, ctr := range runningContainers {
- if err := ctr.Start(r.ctx, true); err != nil {
+ if err := ctr.Start(ctx, true); err != nil {
logrus.Errorf("error restarting container %s", ctr.ID())
}
}