forked from hashicorp/nomad
-
Notifications
You must be signed in to change notification settings - Fork 0
/
operator.go
34 lines (25 loc) · 793 Bytes
/
operator.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
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.
Please see the individual subcommand help for detailed usage information.
`
return strings.TrimSpace(helpText)
}
func (f *OperatorCommand) Synopsis() string {
return "Provides cluster-level tools for Nomad operators"
}
func (f *OperatorCommand) Name() string { return "operator" }
func (f *OperatorCommand) Run(args []string) int {
return cli.RunResultHelp
}