open-nomad/command/operator.go

33 lines
735 B
Go

package command
import (
"strings"
"github.com/mitchellh/cli"
)
type OperatorCommand struct {
Meta
}
func (f *OperatorCommand) Help() string {
helpText := `
Usage: nomad operator <subcommand> [options]
Provides cluster-level tools for Nomad operators, such as interacting with
the Raft subsystem. NOTE: Use this command with extreme caution, as improper
use could lead to a Nomad outage and even loss of data.
Run nomad operator <subcommand> with no arguments for help on that subcommand.
`
return strings.TrimSpace(helpText)
}
func (f *OperatorCommand) Synopsis() string {
return "Provides cluster-level tools for Nomad operators"
}
func (f *OperatorCommand) Run(args []string) int {
return cli.RunResultHelp
}