2016-05-16 11:50:55 -04:00
|
|
|
package plugin
|
|
|
|
|
|
|
|
import (
|
2016-10-06 10:09:54 -04:00
|
|
|
"github.com/docker/docker/cli"
|
2016-09-08 13:11:39 -04:00
|
|
|
"github.com/docker/docker/cli/command"
|
2016-05-16 11:50:55 -04:00
|
|
|
"github.com/spf13/cobra"
|
|
|
|
)
|
|
|
|
|
|
|
|
// NewPluginCommand returns a cobra command for `plugin` subcommands
|
2016-09-19 14:31:53 -04:00
|
|
|
func NewPluginCommand(dockerCli *command.DockerCli) *cobra.Command {
|
2016-10-06 10:09:54 -04:00
|
|
|
cmd := &cobra.Command{
|
|
|
|
Use: "plugin",
|
|
|
|
Short: "Manage plugins",
|
|
|
|
Args: cli.NoArgs,
|
2016-11-17 13:54:10 -05:00
|
|
|
RunE: dockerCli.ShowHelp,
|
2016-10-06 10:09:54 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
cmd.AddCommand(
|
|
|
|
newDisableCommand(dockerCli),
|
|
|
|
newEnableCommand(dockerCli),
|
|
|
|
newInspectCommand(dockerCli),
|
|
|
|
newInstallCommand(dockerCli),
|
|
|
|
newListCommand(dockerCli),
|
|
|
|
newRemoveCommand(dockerCli),
|
|
|
|
newSetCommand(dockerCli),
|
|
|
|
newPushCommand(dockerCli),
|
2016-10-04 15:01:19 -04:00
|
|
|
newCreateCommand(dockerCli),
|
2017-01-28 19:54:32 -05:00
|
|
|
newUpgradeCommand(dockerCli),
|
2016-10-06 10:09:54 -04:00
|
|
|
)
|
|
|
|
return cmd
|
2016-05-16 11:50:55 -04:00
|
|
|
}
|