cmd

package
v0.0.0-...-6515ce2 Latest Latest
Warning

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

Go to latest
Published: Oct 9, 2016 License: Apache-2.0, Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	COMMAND_START_PLUGIN     = "start-plugin"
	COMMAND_STOP_PLUGIN      = "stop-plugin"
	COMMAND_ENABLE_STRATEGY  = "enable-strategy"
	COMMAND_DISABLE_STRATEGY = "disable-strategy"
	COMMAND_UPDATE_DOCUMENT  = "update-document"
)
View Source
const (
	PLUGIN_ENABLE  = "enable"
	PLUGIN_DISABLE = "disable"

	STRATEGY_ENABLE  = "enable"
	STRATEGY_DISABLE = "disable"
)

Variables

View Source
var (
	Host string
	Port string

	DBHost   string
	DBPort   string
	DBUser   string
	DBName   string
	DBPasswd string

	DockerHost string

	AllowedDomain string
)
View Source
var RootCmd = &cobra.Command{
	Use:   "manager",
	Short: "A brief description of your application",
	Long: `A longer description that spans multiple lines and likely contains
examples and usage of using your application. For example:

Cobra is a CLI library for Go that empowers applications.
This application is a tool to generate the needed files
to quickly create a Cobra application.`,
}

RootCmd represents the base command when called without any subcommands

Functions

func Execute

func Execute()

Execute adds all child commands to the root command sets flags appropriately. This is called by main.main(). It only needs to happen once to the rootCmd.

Types

type Command

type Command struct {
	Command string
	Channel string // each plugin subscribe it plugin name, plugin name is channel
	Body    string
}

type ContainerNumberInfo

type ContainerNumberInfo struct {
	Current     int
	Need        int
	ContainerId string
}

type Plugin

type Plugin struct {
	Name        string
	Kind        string
	Status      string
	Description string
	Spec        string
	Manual      string
}

type PluginError

type PluginError struct {
	Code string
	Msg  string
}

type PluginResource

type PluginResource struct {
	// contains filtered or unexported fields
}

func (PluginResource) Register

func (p PluginResource) Register(container *restful.Container)

type ScaleApp

type ScaleApp struct {
	App    string
	Number int
}

type ScaleResult

type ScaleResult struct {
	Scaled []string
	Errors []string
}

type Strategy

type Strategy struct {
	//witch plugin strategy belongs to
	PluginName string
	Name       string
	Status     string
	Document   string
}

Jump to

Keyboard shortcuts

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