2016-05-12 10:52:00 -04:00
|
|
|
// +build experimental
|
|
|
|
|
|
|
|
package checkpoint
|
|
|
|
|
|
|
|
import (
|
|
|
|
"fmt"
|
|
|
|
|
|
|
|
"github.com/spf13/cobra"
|
|
|
|
|
|
|
|
"github.com/docker/docker/cli"
|
|
|
|
"github.com/docker/docker/cli/command"
|
|
|
|
)
|
|
|
|
|
2016-09-19 14:31:53 -04:00
|
|
|
// NewCheckpointCommand returns the `checkpoint` subcommand (only in experimental)
|
|
|
|
func NewCheckpointCommand(dockerCli *command.DockerCli) *cobra.Command {
|
2016-05-12 10:52:00 -04:00
|
|
|
cmd := &cobra.Command{
|
|
|
|
Use: "checkpoint",
|
2016-09-12 11:37:00 -04:00
|
|
|
Short: "Manage checkpoints",
|
2016-05-12 10:52:00 -04:00
|
|
|
Args: cli.NoArgs,
|
|
|
|
Run: func(cmd *cobra.Command, args []string) {
|
|
|
|
fmt.Fprintf(dockerCli.Err(), "\n"+cmd.UsageString())
|
|
|
|
},
|
|
|
|
}
|
|
|
|
cmd.AddCommand(
|
|
|
|
newCreateCommand(dockerCli),
|
|
|
|
newListCommand(dockerCli),
|
|
|
|
newRemoveCommand(dockerCli),
|
|
|
|
)
|
2016-09-19 14:31:53 -04:00
|
|
|
return cmd
|
2016-05-12 10:52:00 -04:00
|
|
|
}
|