Documentation ¶
Index ¶
- type Client
- func (c *Client) Charm(application string) (_ *charm.URL, forceUpgrade bool, sha256 string, vers int, _ error)
- func (c *Client) Life(entityName string) (life.Value, error)
- func (c *Client) Model() (*model.Model, error)
- func (c *Client) RemoveUnit(unitName string) error
- func (c *Client) SetPodSpec(appName string, spec string) error
- func (c *Client) SetStatus(application string, status status.Status, info string, ...) error
- func (c *Client) SetVersion(appName string, v version.Binary) error
- func (c *Client) Watch(application string) (watcher.NotifyWatcher, error)
- func (c *Client) WatchUnits(application string) (watcher.StringsWatcher, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct { *common.APIAddresser // contains filtered or unexported fields }
Client allows access to the CAAS operator API endpoint.
func (*Client) Charm ¶
func (c *Client) Charm(application string) (_ *charm.URL, forceUpgrade bool, sha256 string, vers int, _ error)
Charm returns information about the charm currently assigned to the application, including url, force upgrade and sha etc.
func (*Client) Life ¶
Life returns the lifecycle state for the specified CAAS application or unit in the current model.
func (*Client) RemoveUnit ¶
RemoveUnit removes the specified unit from the current model.
func (*Client) SetPodSpec ¶
SetPodSpec sets the pod spec of the specified application.
func (*Client) SetStatus ¶
func (c *Client) SetStatus( application string, status status.Status, info string, data map[string]interface{}, ) error
SetStatus sets the status of the specified application.
func (*Client) SetVersion ¶
SetVersion sets the tools version associated with the given application.
func (*Client) Watch ¶
func (c *Client) Watch(application string) (watcher.NotifyWatcher, error)
Watch returns a watcher for observing changes to an application.
func (*Client) WatchUnits ¶
func (c *Client) WatchUnits(application string) (watcher.StringsWatcher, error)
WatchUnits returns a StringsWatcher that notifies of changes to the lifecycles of units of the specified CAAS application in the current model.