deployer

package
v0.0.0-...-6cf1bc9 Latest Latest
Warning

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

Go to latest
Published: Oct 13, 2016 License: AGPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Machine

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

Machine represents a juju machine as seen by the deployer worker.

func (*Machine) WatchUnits

func (m *Machine) WatchUnits() (watcher.StringsWatcher, error)

WatchUnits starts a StringsWatcher to watch all units deployed to the machine, in order to track which ones should be deployed or recalled.

type State

type State struct {
	*common.APIAddresser
	// contains filtered or unexported fields
}

State provides access to the deployer worker's idea of the state.

func NewState

func NewState(caller base.APICaller) *State

NewState creates a new State instance that makes API calls through the given caller.

func (*State) ConnectionInfo

func (st *State) ConnectionInfo() (result params.DeployerConnectionValues, err error)

ConnectionInfo returns all the address information that the deployer task needs in one call.

func (*State) Machine

func (st *State) Machine(tag names.MachineTag) (*Machine, error)

Machine returns the machine with the given tag.

func (*State) StateAddresses

func (st *State) StateAddresses() ([]string, error)

StateAddresses returns the list of addresses used to connect to the state.

func (*State) Unit

func (st *State) Unit(tag names.UnitTag) (*Unit, error)

Unit returns the unit with the given tag.

type Unit

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

Unit represents a juju unit as seen by the deployer worker.

func (*Unit) Life

func (u *Unit) Life() params.Life

Life returns the unit's lifecycle value.

func (*Unit) Name

func (u *Unit) Name() string

Name returns the unit's name.

func (*Unit) Refresh

func (u *Unit) Refresh() error

Refresh updates the cached local copy of the unit's data.

func (*Unit) Remove

func (u *Unit) Remove() error

Remove removes the unit from state, calling EnsureDead first, then Remove. It will fail if the unit is not present.

func (*Unit) SetPassword

func (u *Unit) SetPassword(password string) error

SetPassword sets the unit's password.

func (*Unit) SetStatus

func (u *Unit) SetStatus(unitStatus status.Status, info string, data map[string]interface{}) error

SetStatus sets the status of the unit.

func (*Unit) Tag

func (u *Unit) Tag() string

Tag returns the unit's tag.

Jump to

Keyboard shortcuts

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