Skip to content

Commit e08a3be

Browse files
authored
docs: touch ups to harmonize rendering on docs website (#76)
* docs: touch ups to harmonize rendering on docs website * gen docs * go fmt
1 parent a74b31a commit e08a3be

34 files changed

+159
-104
lines changed

cmd/docker-mcp/commands/client.go

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ func connectClientCommand(cwd string, cfg client.Config) *cobra.Command {
5151
}
5252
cmd := &cobra.Command{
5353
Use: fmt.Sprintf("connect [OPTIONS] <mcp-client>\n\nSupported clients: %s", strings.Join(client.GetSupportedMCPClients(cfg), " ")),
54-
Short: "Connect the Docker MCP Toolkit to a client",
54+
Short: fmt.Sprintf("Connect the Docker MCP Toolkit to a client. Supported clients: %s", strings.Join(client.GetSupportedMCPClients(cfg), " ")),
5555
Args: cobra.ExactArgs(1),
5656
RunE: func(cmd *cobra.Command, args []string) error {
5757
return client.Connect(cmd.Context(), cwd, cfg, args[0], opts.Global, opts.Quiet)
@@ -70,7 +70,7 @@ func disconnectClientCommand(cwd string, cfg client.Config) *cobra.Command {
7070
}
7171
cmd := &cobra.Command{
7272
Use: fmt.Sprintf("disconnect [OPTIONS] <mcp-client>\n\nSupported clients: %s", strings.Join(client.GetSupportedMCPClients(cfg), " ")),
73-
Short: "Disconnect the Docker MCP Toolkit from a client",
73+
Short: fmt.Sprintf("Disconnect the Docker MCP Toolkit from a client. Supported clients: %s", strings.Join(client.GetSupportedMCPClients(cfg), " ")),
7474
Args: cobra.ExactArgs(1),
7575
RunE: func(cmd *cobra.Command, args []string) error {
7676
return client.Disconnect(cmd.Context(), cwd, cfg, args[0], opts.Global, opts.Quiet)
@@ -84,8 +84,9 @@ func disconnectClientCommand(cwd string, cfg client.Config) *cobra.Command {
8484

8585
func manualClientCommand() *cobra.Command {
8686
cmd := &cobra.Command{
87-
Use: "manual-instructions",
88-
Args: cobra.NoArgs,
87+
Use: "manual-instructions",
88+
Short: "Display the manual instructions to connect the MCP client",
89+
Args: cobra.NoArgs,
8990
RunE: func(cmd *cobra.Command, _ []string) error {
9091
printAsJSON, err := cmd.Flags().GetBool("json")
9192
if err != nil {

cmd/docker-mcp/commands/gateway.go

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -86,14 +86,14 @@ func gatewayCommand(docker docker.Client) *cobra.Command {
8686
},
8787
}
8888

89-
runCmd.Flags().StringSliceVar(&options.ServerNames, "servers", nil, "names of the servers to enable (if non empty, ignore --registry flag)")
90-
runCmd.Flags().StringSliceVar(&options.CatalogPath, "catalog", options.CatalogPath, "paths to docker catalogs (absolute or relative to ~/.docker/mcp/catalogs/)")
91-
runCmd.Flags().StringSliceVar(&additionalCatalogs, "additional-catalog", nil, "additional catalog paths to append to the default catalogs")
92-
runCmd.Flags().StringSliceVar(&options.RegistryPath, "registry", options.RegistryPath, "paths to the registry files (absolute or relative to ~/.docker/mcp/)")
93-
runCmd.Flags().StringSliceVar(&additionalRegistries, "additional-registry", nil, "additional registry paths to merge with the default registry.yaml")
94-
runCmd.Flags().StringSliceVar(&options.ConfigPath, "config", options.ConfigPath, "paths to the config files (absolute or relative to ~/.docker/mcp/)")
95-
runCmd.Flags().StringSliceVar(&additionalConfigs, "additional-config", nil, "additional config paths to merge with the default config.yaml")
96-
runCmd.Flags().StringVar(&options.SecretsPath, "secrets", options.SecretsPath, "colon separated paths to search for secrets. Can be `docker-desktop` or a path to a .env file (default to using Docker Deskop's secrets API)")
89+
runCmd.Flags().StringSliceVar(&options.ServerNames, "servers", nil, "Names of the servers to enable (if non empty, ignore --registry flag)")
90+
runCmd.Flags().StringSliceVar(&options.CatalogPath, "catalog", options.CatalogPath, "Paths to docker catalogs (absolute or relative to ~/.docker/mcp/catalogs/)")
91+
runCmd.Flags().StringSliceVar(&additionalCatalogs, "additional-catalog", nil, "Additional catalog paths to append to the default catalogs")
92+
runCmd.Flags().StringSliceVar(&options.RegistryPath, "registry", options.RegistryPath, "Paths to the registry files (absolute or relative to ~/.docker/mcp/)")
93+
runCmd.Flags().StringSliceVar(&additionalRegistries, "additional-registry", nil, "Additional registry paths to merge with the default registry.yaml")
94+
runCmd.Flags().StringSliceVar(&options.ConfigPath, "config", options.ConfigPath, "Paths to the config files (absolute or relative to ~/.docker/mcp/)")
95+
runCmd.Flags().StringSliceVar(&additionalConfigs, "additional-config", nil, "Additional config paths to merge with the default config.yaml")
96+
runCmd.Flags().StringVar(&options.SecretsPath, "secrets", options.SecretsPath, "Colon separated paths to search for secrets. Can be `docker-desktop` or a path to a .env file (default to using Docker Desktop's secrets API)")
9797
runCmd.Flags().StringSliceVar(&options.ToolNames, "tools", options.ToolNames, "List of tools to enable")
9898
runCmd.Flags().StringArrayVar(&options.Interceptors, "interceptor", options.Interceptors, "List of interceptors to use (format: when:type:path, e.g. 'before:exec:/bin/path')")
9999
runCmd.Flags().IntVar(&options.Port, "port", options.Port, "TCP port to listen on (default is to listen on stdio)")

cmd/docker-mcp/commands/oauth.go

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,9 @@ func lsOauthCommand() *cobra.Command {
3636

3737
func authorizeOauthCommand() *cobra.Command {
3838
return &cobra.Command{
39-
Use: "authorize <app>",
40-
Args: cobra.ExactArgs(1),
39+
Use: "authorize <app>",
40+
Short: "Authorize the specified OAuth app.",
41+
Args: cobra.ExactArgs(1),
4142
RunE: func(cmd *cobra.Command, args []string) error {
4243
return oauth.Authorize(cmd.Context(), args[0])
4344
},
@@ -46,8 +47,9 @@ func authorizeOauthCommand() *cobra.Command {
4647

4748
func revokeOauthCommand() *cobra.Command {
4849
return &cobra.Command{
49-
Use: "revoke <app>",
50-
Args: cobra.ExactArgs(1),
50+
Use: "revoke <app>",
51+
Args: cobra.ExactArgs(1),
52+
Short: "Revoke the specified OAuth app.",
5153
RunE: func(cmd *cobra.Command, args []string) error {
5254
return oauth.Revoke(cmd.Context(), args[0])
5355
},

cmd/docker-mcp/commands/policy.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,13 @@ import (
1111
)
1212

1313
const setPolicyExample = `
14-
# Backup the current policy to a file
14+
### Backup the current policy to a file
1515
docker mcp policy dump > policy.conf
1616
17-
# Set a new policy
17+
### Set a new policy
1818
docker mcp policy set "my-secret allows postgres"
1919
20-
# Restore the previous policy
20+
### Restore the previous policy
2121
cat policy.conf | docker mcp policy set
2222
`
2323

cmd/docker-mcp/commands/root.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ Examples:
3333
func Root(ctx context.Context, cwd string, dockerCli command.Cli) *cobra.Command {
3434
cmd := &cobra.Command{
3535
Use: "mcp [OPTIONS]",
36+
Short: "Manage MCP servers and clients",
3637
TraverseChildren: true,
3738
CompletionOptions: cobra.CompletionOptions{
3839
DisableDefaultCmd: false,

cmd/docker-mcp/commands/secret.go

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,15 @@ import (
1212
)
1313

1414
const setSecretExample = `
15-
# Using secrets for postgres password with default policy:
16-
docker mcp secret set POSTGRES_PASSWORD=my-secret-password
17-
docker run -d -l x-secret:POSTGRES_PASSWORD=/pwd.txt -e POSTGRES_PASSWORD_FILE=/pwd.txt -p 5432 postgres
15+
### Use secrets for postgres password with default policy
1816
19-
# Or pass the secret via STDIN:
20-
echo my-secret-password > pwd.txt
21-
cat pwd.txt | docker mcp secret set POSTGRES_PASSWORD
17+
> docker mcp secret set POSTGRES_PASSWORD=my-secret-password
18+
> docker run -d -l x-secret:POSTGRES_PASSWORD=/pwd.txt -e POSTGRES_PASSWORD_FILE=/pwd.txt -p 5432 postgres
19+
20+
### Pass the secret via STDIN
21+
22+
> echo my-secret-password > pwd.txt
23+
> cat pwd.txt | docker mcp secret set POSTGRES_PASSWORD
2224
`
2325

2426
func secretCommand(docker docker.Client) *cobra.Command {

cmd/docker-mcp/commands/server.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ func serverCommand(docker docker.Client) *cobra.Command {
2222
lsCommand := &cobra.Command{
2323
Use: "list",
2424
Aliases: []string{"ls"},
25-
Short: "list enabled servers",
25+
Short: "List enabled servers",
2626
Args: cobra.NoArgs,
2727
RunE: func(cmd *cobra.Command, _ []string) error {
2828
list, err := server.List(cmd.Context(), docker)

cmd/docker-mcp/commands/tools.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ func toolsCommand() *cobra.Command {
2626
cmd.AddCommand(&cobra.Command{
2727
Use: "list",
2828
Aliases: []string{"ls"},
29-
Short: "list tools",
29+
Short: "List tools",
3030
Args: cobra.NoArgs,
3131
RunE: func(cmd *cobra.Command, _ []string) error {
3232
return tools.List(cmd.Context(), version, gatewayArgs, verbose, "list", "", format)
@@ -35,7 +35,7 @@ func toolsCommand() *cobra.Command {
3535

3636
cmd.AddCommand(&cobra.Command{
3737
Use: "count",
38-
Short: "count tools",
38+
Short: "Count tools",
3939
Args: cobra.NoArgs,
4040
RunE: func(cmd *cobra.Command, _ []string) error {
4141
return tools.List(cmd.Context(), version, gatewayArgs, verbose, "count", "", format)
@@ -44,15 +44,15 @@ func toolsCommand() *cobra.Command {
4444

4545
cmd.AddCommand(&cobra.Command{
4646
Use: "inspect",
47-
Short: "inspect a tool",
47+
Short: "Inspect a tool",
4848
Args: cobra.ExactArgs(1),
4949
RunE: func(cmd *cobra.Command, args []string) error {
5050
return tools.List(cmd.Context(), version, gatewayArgs, verbose, "inspect", args[0], format)
5151
},
5252
})
5353
cmd.AddCommand(&cobra.Command{
5454
Use: "call",
55-
Short: "call a tool",
55+
Short: "Call a tool",
5656
RunE: func(cmd *cobra.Command, args []string) error {
5757
return tools.Call(cmd.Context(), version, gatewayArgs, verbose, args)
5858
},

docs/generator/reference/docker_mcp.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,11 @@
11
command: docker mcp
2+
short: Manage MCP servers and clients
3+
long: |-
4+
The MCP Gateway is Docker's open-source enterprise solution for orchestrating
5+
Model Context Protocol (MCP) servers and clients.
6+
7+
For more information see [Docker MCP](/ai/mcp-gateway/) and
8+
the public [GitHub repository](https://github.com/docker/mcp-gateway).
29
pname: docker
310
plink: docker.yaml
411
cname:

docs/generator/reference/docker_mcp_client_connect.yaml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
command: docker mcp client connect
2-
short: Connect the Docker MCP Toolkit to a client
3-
long: Connect the Docker MCP Toolkit to a client
2+
short: |
3+
Connect the Docker MCP Toolkit to a client. Supported clients: claude-desktop continue cursor gemini goose gordon lmstudio sema4 vscode
4+
long: |
5+
Connect the Docker MCP Toolkit to a client. Supported clients: claude-desktop continue cursor gemini goose gordon lmstudio sema4 vscode
46
usage: |-
57
docker mcp client connect [OPTIONS] <mcp-client>
68

0 commit comments

Comments
 (0)