From 99086026bc24e3521154200f4eae9ca803093cf5 Mon Sep 17 00:00:00 2001 From: erxian Date: Fri, 18 Nov 2016 14:28:21 +0800 Subject: [PATCH] update secret command Signed-off-by: erxian Upstream-commit: d87c91e39ff0d3defb5b98fdc9275c8c0bfc987e Component: engine --- components/engine/cli/command/secret/create.go | 2 +- components/engine/cli/command/secret/inspect.go | 4 ++-- components/engine/cli/command/secret/ls.go | 2 +- components/engine/cli/command/secret/remove.go | 4 ++-- components/engine/docs/reference/commandline/secret_create.md | 4 +--- 5 files changed, 7 insertions(+), 9 deletions(-) diff --git a/components/engine/cli/command/secret/create.go b/components/engine/cli/command/secret/create.go index da1cb9275e..faef32ef89 100644 --- a/components/engine/cli/command/secret/create.go +++ b/components/engine/cli/command/secret/create.go @@ -25,7 +25,7 @@ func newSecretCreateCommand(dockerCli *command.DockerCli) *cobra.Command { } cmd := &cobra.Command{ - Use: "create [name]", + Use: "create [OPTIONS] SECRET [SECRET...]", Short: "Create a secret using stdin as content", Args: cli.RequiresMinArgs(1), RunE: func(cmd *cobra.Command, args []string) error { diff --git a/components/engine/cli/command/secret/inspect.go b/components/engine/cli/command/secret/inspect.go index a82a26e4a8..1dda6f7838 100644 --- a/components/engine/cli/command/secret/inspect.go +++ b/components/engine/cli/command/secret/inspect.go @@ -16,8 +16,8 @@ type inspectOptions struct { func newSecretInspectCommand(dockerCli *command.DockerCli) *cobra.Command { opts := inspectOptions{} cmd := &cobra.Command{ - Use: "inspect SECRET [SECRET]", - Short: "Inspect a secret", + Use: "inspect [OPTIONS] SECRET [SECRET...]", + Short: "Display detailed information on one or more secrets", Args: cli.RequiresMinArgs(1), RunE: func(cmd *cobra.Command, args []string) error { opts.names = args diff --git a/components/engine/cli/command/secret/ls.go b/components/engine/cli/command/secret/ls.go index e99f99e3d2..d96b377867 100644 --- a/components/engine/cli/command/secret/ls.go +++ b/components/engine/cli/command/secret/ls.go @@ -21,7 +21,7 @@ func newSecretListCommand(dockerCli *command.DockerCli) *cobra.Command { opts := listOptions{} cmd := &cobra.Command{ - Use: "ls", + Use: "ls [OPTIONS]", Short: "List secrets", Args: cli.NoArgs, RunE: func(cmd *cobra.Command, args []string) error { diff --git a/components/engine/cli/command/secret/remove.go b/components/engine/cli/command/secret/remove.go index 75b4be622b..5026a437f8 100644 --- a/components/engine/cli/command/secret/remove.go +++ b/components/engine/cli/command/secret/remove.go @@ -15,8 +15,8 @@ type removeOptions struct { func newSecretRemoveCommand(dockerCli *command.DockerCli) *cobra.Command { return &cobra.Command{ - Use: "rm SECRET [SECRET]", - Short: "Remove a secret", + Use: "rm SECRET [SECRET...]", + Short: "Remove one or more secrets", Args: cli.RequiresMinArgs(1), RunE: func(cmd *cobra.Command, args []string) error { opts := removeOptions{ diff --git a/components/engine/docs/reference/commandline/secret_create.md b/components/engine/docs/reference/commandline/secret_create.md index 6a124d5383..952ad26b2c 100644 --- a/components/engine/docs/reference/commandline/secret_create.md +++ b/components/engine/docs/reference/commandline/secret_create.md @@ -16,7 +16,7 @@ keywords: ["secret, create"] # secret create ```Markdown -Usage: docker secret create [NAME] +Usage: docker secret create [OPTIONS] SECRET Create a secret using stdin as content Options: @@ -76,5 +76,3 @@ $ docker secret inspect secret.json * [secret inspect](secret_inspect.md) * [secret ls](secret_ls.md) * [secret rm](secret_rm.md) - -