master

package
v0.0.0-...-cd5e839 Latest Latest
Warning

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

Go to latest
Published: Apr 3, 2019 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Mode   string          `yaml:"mode" json:"mode" default:"docker" validate:"regexp=^(native|docker)$"`
	Server http.ServerInfo `yaml:"server" json:"server"`
	Logger logger.LogInfo  `yaml:"logger" json:"logger"`
	Grace  time.Duration   `yaml:"grace" json:"grace" default:"30s"`
}

Config master init config

type Master

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

Master master manages all modules and connects with cloud

func New

func New(pwd string, cfg Config, ver string) (*Master, error)

New creates a new master

func (*Master) Auth

func (m *Master) Auth(username, password string) bool

Auth auth api request from services

func (*Master) Close

func (m *Master) Close() error

Close closes agent

func (*Master) InspectSystem

func (m *Master) InspectSystem() *openedge.Inspect

InspectSystem inspects system

func (*Master) StartServiceInstance

func (m *Master) StartServiceInstance(service, instance string, dynamicConfig map[string]string) error

StartServiceInstance starts a service instance

func (*Master) StopServiceInstance

func (m *Master) StopServiceInstance(service, instance string) error

StopServiceInstance stops a service instance

func (*Master) UpdateSystem

func (m *Master) UpdateSystem(dir string, clean bool) error

UpdateSystem updates system

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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