Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type State

type State struct {
	// contains filtered or unexported fields

}

State provides access to an upgrader worker's view of the state.

func NewState

func NewState(caller base.APICaller) *State

NewState returns a version of the state that provides functionality required by the upgrader worker.

func (*State) DesiredVersion

func (st *State) DesiredVersion(tag string) (version.Number, error)

func (*State) SetVersion

func (st *State) SetVersion(tag string, v version.Binary) error

SetVersion sets the tools version associated with the entity with the given tag, which must be the tag of the entity that the upgrader is running on behalf of.

func (*State) Tools

func (st *State) Tools(tag string) (tools.List, error)

Tools returns the agent tools that should run on the given entity, along with a flag whether to disable SSL hostname verification.

func (*State) WatchAPIVersion

func (st *State) WatchAPIVersion(agentTag string) (watcher.NotifyWatcher, error)

Source Files