butler

package
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2018 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrBmcConnectionFail = errors.New("Unable to login to bmc") //could be a timeout or just bad credentials.
	ErrUnkownAsset       = errors.New("Unknown asset type")
)

Functions

This section is empty.

Types

type Butler

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

func (*Butler) Run

func (b *Butler) Run()

butler recieves bmc config, assets over channel iterate over assets and apply config

func (*Butler) SetupChassis added in v0.0.5

func (b *Butler) SetupChassis(assetConfig *cfgresources.SetupChassis, asset *asset.Asset, connection devices.BmcChassis) (err error)

type ButlerManager

type ButlerManager struct {
	Config         *config.Params //bmcbutler config, cli params
	ButlerChan     <-chan ButlerMsg
	Log            *logrus.Logger
	MetricsEmitter *metrics.Emitter
	SyncWG         *sync.WaitGroup
}

func (*ButlerManager) SpawnButlers

func (bm *ButlerManager) SpawnButlers()

spawn a pool of butlers, wait until they are done.

type ButlerMsg

type ButlerMsg struct {
	Asset        asset.Asset //Asset to be configured
	AssetConfig  []byte      //The BMC configuration read in from configuration.yml
	AssetSetup   []byte      //The One time setup configuration read from setup.yml
	AssetExecute string      //Commands to be executed on the BMC
}

type SetupChassis added in v0.0.5

type SetupChassis struct {
	Asset          *asset.Asset
	Config         *config.Params //bmcbutler config, cli params
	Chassis        devices.BmcChassis
	AssetConfig    *cfgresources.SetupChassis
	MetricsEmitter *metrics.Emitter
	Id             int
	Log            *logrus.Logger
}

func (*SetupChassis) Post added in v0.0.5

func (s *SetupChassis) Post(asset *asset.Asset)

Actions to be taken once a chassis was setup successfully.

Jump to

Keyboard shortcuts

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