mirror of https://github.com/kubernetes/kops.git
Clean up "kops export"
This commit is contained in:
parent
46aafd55a8
commit
3091b76ffc
|
|
@ -22,28 +22,17 @@ import (
|
||||||
"github.com/spf13/cobra"
|
"github.com/spf13/cobra"
|
||||||
"k8s.io/kops/cmd/kops/util"
|
"k8s.io/kops/cmd/kops/util"
|
||||||
"k8s.io/kubectl/pkg/util/i18n"
|
"k8s.io/kubectl/pkg/util/i18n"
|
||||||
"k8s.io/kubectl/pkg/util/templates"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
exportLong = templates.LongDesc(i18n.T(`
|
|
||||||
Export configurations from a cluster.`))
|
|
||||||
|
|
||||||
exportExample = templates.Examples(i18n.T(`
|
|
||||||
# export a kubecfg file
|
|
||||||
kops export kubecfg k8s-cluster.example.com
|
|
||||||
`))
|
|
||||||
|
|
||||||
exportShort = i18n.T(`Export configuration.`)
|
exportShort = i18n.T(`Export configuration.`)
|
||||||
)
|
)
|
||||||
|
|
||||||
func NewCmdExport(f *util.Factory, out io.Writer) *cobra.Command {
|
func NewCmdExport(f *util.Factory, out io.Writer) *cobra.Command {
|
||||||
|
|
||||||
cmd := &cobra.Command{
|
cmd := &cobra.Command{
|
||||||
Use: "export",
|
Use: "export",
|
||||||
Short: exportShort,
|
Short: exportShort,
|
||||||
Long: exportLong,
|
|
||||||
Example: exportExample,
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// create subcommands
|
// create subcommands
|
||||||
|
|
|
||||||
|
|
@ -5,17 +5,6 @@
|
||||||
|
|
||||||
Export configuration.
|
Export configuration.
|
||||||
|
|
||||||
### Synopsis
|
|
||||||
|
|
||||||
Export configurations from a cluster.
|
|
||||||
|
|
||||||
### Examples
|
|
||||||
|
|
||||||
```
|
|
||||||
# export a kubecfg file
|
|
||||||
kops export kubecfg k8s-cluster.example.com
|
|
||||||
```
|
|
||||||
|
|
||||||
### Options
|
### Options
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue