Add support for specifying a checkpoint directory. (#245)

Signed-off-by: Ross Boucher <rboucher@gmail.com>
This commit is contained in:
Ross Boucher
2016-05-25 20:42:37 -04:00
committed by Michael Crosby
parent 76dd6710dc
commit e756ae42d1
10 changed files with 291 additions and 228 deletions

View File

@@ -134,6 +134,11 @@ var startCommand = cli.Command{
Value: "",
Usage: "checkpoint to start the container from",
},
cli.StringFlag{
Name: "checkpoint-dir",
Value: "",
Usage: "path to checkpoint directory",
},
cli.BoolFlag{
Name: "attach,a",
Usage: "connect to the stdio of the container",
@@ -177,14 +182,15 @@ var startCommand = cli.Command{
tty bool
c = getClient(context)
r = &types.CreateContainerRequest{
Id: id,
BundlePath: bpath,
Checkpoint: context.String("checkpoint"),
Stdin: s.stdin,
Stdout: s.stdout,
Stderr: s.stderr,
Labels: context.StringSlice("label"),
NoPivotRoot: context.Bool("no-pivot"),
Id: id,
BundlePath: bpath,
Checkpoint: context.String("checkpoint"),
CheckpointDir: context.String("checkpoint-dir"),
Stdin: s.stdin,
Stdout: s.stdout,
Stderr: s.stderr,
Labels: context.StringSlice("label"),
NoPivotRoot: context.Bool("no-pivot"),
}
)
restoreAndCloseStdin = func() {