command

package
Version: v1.12.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 11, 2020 License: Apache-2.0 Imports: 26 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckError

func CheckError(err error)

CheckError prints err to stderr and exits with code 1 if err is not nil. Otherwise, it is a no-op.

func NewCmdStart

func NewCmdStart() *cobra.Command

NewCmdStart creates start command for maya-apiserver

func NewCmdVersion

func NewCmdVersion() *cobra.Command

NewCmdVersion creates the version command

func NewCommand

func NewCommand() *cobra.Command

NewCommand creates the `maya-apiserver` command and its nested children.

func Run

func Run(cmd *cobra.Command, c *CmdStartOptions) error

Run does tasks related to mayaserver.

Types

type CmdStartOptions

type CmdStartOptions struct {
	BindAddr   string
	LogLevel   string
	ConfigPath string
	ShutdownCh <-chan struct{}
	// contains filtered or unexported fields
}

CmdStartOptions is a cli implementation that runs a maya apiserver. The command will not end unless a shutdown message is sent on the ShutdownCh. If two messages are sent on the ShutdownCh it will forcibly exit.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL