2017-10-17 06:03:03 +00:00
|
|
|
package operraft
|
2017-02-15 21:30:07 +00:00
|
|
|
|
|
|
|
import (
|
2017-10-05 15:30:25 +00:00
|
|
|
"github.com/mitchellh/cli"
|
2017-02-15 21:30:07 +00:00
|
|
|
)
|
|
|
|
|
2017-10-17 06:03:03 +00:00
|
|
|
func New() *cmd {
|
|
|
|
return &cmd{}
|
2017-02-15 21:30:07 +00:00
|
|
|
}
|
|
|
|
|
2017-10-17 06:03:03 +00:00
|
|
|
type cmd struct{}
|
|
|
|
|
|
|
|
func (c *cmd) Run(args []string) int {
|
2017-10-05 15:30:25 +00:00
|
|
|
return cli.RunResultHelp
|
|
|
|
}
|
|
|
|
|
2017-10-17 06:03:03 +00:00
|
|
|
func (c *cmd) Synopsis() string {
|
|
|
|
return "Provides cluster-level tools for Consul operators"
|
|
|
|
}
|
|
|
|
|
|
|
|
func (c *cmd) Help() string {
|
|
|
|
s := `
|
2017-02-15 21:30:07 +00:00
|
|
|
Usage: consul operator raft <subcommand> [options]
|
|
|
|
|
|
|
|
The Raft operator command is used to interact with Consul's Raft subsystem. The
|
|
|
|
command can be used to verify Raft peers or in rare cases to recover quorum by
|
|
|
|
removing invalid peers.
|
|
|
|
|
|
|
|
`
|
2017-10-17 06:03:03 +00:00
|
|
|
return s
|
2017-02-15 21:30:07 +00:00
|
|
|
}
|