mirror of https://github.com/kubernetes/kops.git
parent
b604917142
commit
17b3fa36eb
|
|
@ -21,6 +21,11 @@ import (
|
||||||
"github.com/spf13/cobra/doc"
|
"github.com/spf13/cobra/doc"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
const fileHeader = `
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
|
`
|
||||||
|
|
||||||
type GenHelpDocsCmd struct {
|
type GenHelpDocsCmd struct {
|
||||||
cobraCommand *cobra.Command
|
cobraCommand *cobra.Command
|
||||||
OutDir string
|
OutDir string
|
||||||
|
|
@ -55,5 +60,9 @@ func (c *GenHelpDocsCmd) Run() error {
|
||||||
for _, c := range rootCommand.cobraCommand.Commands() {
|
for _, c := range rootCommand.cobraCommand.Commands() {
|
||||||
c.Flag("state").DefValue = ""
|
c.Flag("state").DefValue = ""
|
||||||
}
|
}
|
||||||
return doc.GenMarkdownTree(rootCommand.cobraCommand, c.OutDir)
|
|
||||||
|
linkHandler := func(link string) string { return link }
|
||||||
|
filePrepender := func(filname string) string { return fileHeader }
|
||||||
|
|
||||||
|
return doc.GenMarkdownTreeCustom(rootCommand.cobraCommand, c.OutDir, filePrepender, linkHandler)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops
|
## kops
|
||||||
|
|
||||||
kops is Kubernetes ops.
|
kops is Kubernetes ops.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops completion
|
## kops completion
|
||||||
|
|
||||||
Output shell completion code for the given shell (bash or zsh).
|
Output shell completion code for the given shell (bash or zsh).
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops create
|
## kops create
|
||||||
|
|
||||||
Create a resource by command line, filename or stdin.
|
Create a resource by command line, filename or stdin.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops create cluster
|
## kops create cluster
|
||||||
|
|
||||||
Create a Kubernetes cluster.
|
Create a Kubernetes cluster.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops create instancegroup
|
## kops create instancegroup
|
||||||
|
|
||||||
Create an instancegroup.
|
Create an instancegroup.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops create secret
|
## kops create secret
|
||||||
|
|
||||||
Create a secret.
|
Create a secret.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops create secret sshpublickey
|
## kops create secret sshpublickey
|
||||||
|
|
||||||
Create a ssh public key.
|
Create a ssh public key.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops delete
|
## kops delete
|
||||||
|
|
||||||
Delete clusters,instancegroups, or secrets.
|
Delete clusters,instancegroups, or secrets.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops delete cluster
|
## kops delete cluster
|
||||||
|
|
||||||
Delete a cluster.
|
Delete a cluster.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops delete instancegroup
|
## kops delete instancegroup
|
||||||
|
|
||||||
Delete instancegroup
|
Delete instancegroup
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops delete secret
|
## kops delete secret
|
||||||
|
|
||||||
Delete a secret
|
Delete a secret
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops describe
|
## kops describe
|
||||||
|
|
||||||
Describe a resource.
|
Describe a resource.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops describe secrets
|
## kops describe secrets
|
||||||
|
|
||||||
Describe a cluster secret
|
Describe a cluster secret
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops edit
|
## kops edit
|
||||||
|
|
||||||
Edit clusters and other resources.
|
Edit clusters and other resources.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops edit cluster
|
## kops edit cluster
|
||||||
|
|
||||||
Edit cluster.
|
Edit cluster.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops edit federation
|
## kops edit federation
|
||||||
|
|
||||||
Edit federation.
|
Edit federation.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops edit instancegroup
|
## kops edit instancegroup
|
||||||
|
|
||||||
Edit instancegroup.
|
Edit instancegroup.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops export
|
## kops export
|
||||||
|
|
||||||
Export configuration.
|
Export configuration.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops export kubecfg
|
## kops export kubecfg
|
||||||
|
|
||||||
Export kubecfg.
|
Export kubecfg.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops get
|
## kops get
|
||||||
|
|
||||||
Get one or many resources.
|
Get one or many resources.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops get clusters
|
## kops get clusters
|
||||||
|
|
||||||
Get one or many clusters.
|
Get one or many clusters.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops get federations
|
## kops get federations
|
||||||
|
|
||||||
Get federation.
|
Get federation.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops get instancegroups
|
## kops get instancegroups
|
||||||
|
|
||||||
Get one or many instancegroups
|
Get one or many instancegroups
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops get secrets
|
## kops get secrets
|
||||||
|
|
||||||
Get one or many secrets.
|
Get one or many secrets.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops import
|
## kops import
|
||||||
|
|
||||||
Import a cluster.
|
Import a cluster.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops import cluster
|
## kops import cluster
|
||||||
|
|
||||||
Import a cluster.
|
Import a cluster.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops replace
|
## kops replace
|
||||||
|
|
||||||
Replace cluster resources.
|
Replace cluster resources.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops rolling-update
|
## kops rolling-update
|
||||||
|
|
||||||
Rolling update a cluster.
|
Rolling update a cluster.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops rolling-update cluster
|
## kops rolling-update cluster
|
||||||
|
|
||||||
Rolling update a cluster.
|
Rolling update a cluster.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops toolbox
|
## kops toolbox
|
||||||
|
|
||||||
Misc infrequently used commands.
|
Misc infrequently used commands.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops toolbox convert-imported
|
## kops toolbox convert-imported
|
||||||
|
|
||||||
Convert an imported cluster into a kops cluster.
|
Convert an imported cluster into a kops cluster.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops toolbox dump
|
## kops toolbox dump
|
||||||
|
|
||||||
Dump cluster information
|
Dump cluster information
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops update
|
## kops update
|
||||||
|
|
||||||
Update a cluster.
|
Update a cluster.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops update cluster
|
## kops update cluster
|
||||||
|
|
||||||
Update a cluster.
|
Update a cluster.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops update federation
|
## kops update federation
|
||||||
|
|
||||||
Update federation cluster resources.
|
Update federation cluster resources.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops upgrade
|
## kops upgrade
|
||||||
|
|
||||||
Upgrade a kubernetes cluster.
|
Upgrade a kubernetes cluster.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops upgrade cluster
|
## kops upgrade cluster
|
||||||
|
|
||||||
Upgrade a kubernetes cluster.
|
Upgrade a kubernetes cluster.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops validate
|
## kops validate
|
||||||
|
|
||||||
Validate a kops cluster.
|
Validate a kops cluster.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops validate cluster
|
## kops validate cluster
|
||||||
|
|
||||||
Validate a kops cluster.
|
Validate a kops cluster.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
|
||||||
|
<!--- This file is automatically generated by make gen-cli-docs; changes should be made in the go CLI command code (under cmd/kops) -->
|
||||||
|
|
||||||
## kops version
|
## kops version
|
||||||
|
|
||||||
Print the kops version information.
|
Print the kops version information.
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue