Documentation
¶
Overview ¶
The controller package groups various commands that are based on talking directly to the controller, and not environments in the controller.
Index ¶
- func NewCreateModelCommand() cmd.Command
- func NewDestroyCommand() cmd.Command
- func NewKillCommand() cmd.Command
- func NewListBlocksCommand() cmd.Command
- func NewListControllersCommand() cmd.Command
- func NewListModelsCommand() cmd.Command
- func NewRegisterCommand() cmd.Command
- func NewRemoveBlocksCommand() cmd.Command
- func NewShowControllerCommand() cmd.Command
- type AccountDetails
- type ControllerDetails
- type ControllerItem
- type ControllerSet
- type CreateModelAPI
- type ModelDetails
- type ModelManagerAPI
- type ModelSet
- type ModelsSysAPI
- type ShowControllerDetails
- type UserModel
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewCreateModelCommand ¶
NewCreateModelCommand returns a command to create an model.
func NewDestroyCommand ¶
NewDestroyCommand returns a command to destroy a controller.
func NewKillCommand ¶
NewKillCommand returns a command to kill a controller. Killing is a forceful destroy.
func NewListBlocksCommand ¶
NewListBlocksCommand returns a command to list the blocks in a controller.
func NewListControllersCommand ¶
NewListControllersCommand returns a command to list registered controllers.
func NewListModelsCommand ¶
NewListModelsCommand returns a command to list models.
func NewRegisterCommand ¶
NewRegisterCommand returns a command to allow the user to register a controller.
func NewRemoveBlocksCommand ¶
NewRemoveBlocksCommand returns a command that allows a controller admin to remove blocks from the controller.
Types ¶
type AccountDetails ¶
type AccountDetails struct {
// User is the username for the account.
User string `yaml:"user" json:"user"`
// Password is the password for the account.
Password string `yaml:"password,omitempty" json:"password,omitempty"`
// Models is a collection of all models for this controller.
Models map[string]ModelDetails `yaml:"models,omitempty" json:"models,omitempty"`
// CurrentModel is the name of the current model for this controller
CurrentModel string `yaml:"current-model,omitempty" json:"current-model,omitempty"`
}
AccountDetails holds details of an account to show.
type ControllerDetails ¶
type ControllerDetails struct {
// Servers contains the addresses of hosts that form this controller's cluster.
Servers []string `yaml:"servers,flow" json:"servers"`
// ControllerUUID is the unique ID for the controller.
ControllerUUID string `yaml:"uuid" json:"uuid"`
// APIEndpoints is the collection of API endpoints running in this controller.
APIEndpoints []string `yaml:"api-endpoints,flow" json:"api-endpoints"`
// CACert is a security certificate for this controller.
CACert string `yaml:"ca-cert" json:"ca-cert"`
}
ControllerDetails holds details of a controller to show.
type ControllerItem ¶
type ControllerItem struct {
ModelName string `yaml:"current-model,omitempty" json:"current-model,omitempty"`
User string `yaml:"user,omitempty" json:"user,omitempty"`
Server string `yaml:"recent-server,omitempty" json:"recent-server,omitempty"`
Servers []string `yaml:"servers,flow" json:"servers"`
ControllerUUID string `yaml:"uuid" json:"uuid"`
APIEndpoints []string `yaml:"api-endpoints,flow" json:"api-endpoints"`
CACert string `yaml:"ca-cert" json:"ca-cert"`
}
ControllerItem defines the serialization behaviour of controller information.
type ControllerSet ¶
type ControllerSet struct {
Controllers map[string]ControllerItem `yaml:"controllers" json:"controllers"`
CurrentController string `yaml:"current-controller" json:"current-controller"`
}
ControllerSet contains the set of controllers known to the client, and name of the current controller.
type CreateModelAPI ¶
type ModelDetails ¶
type ModelDetails struct {
// ModelUUID holds the details of a model.
ModelUUID string `yaml:"uuid" json:"uuid"`
}
ModelDetails holds details of a model to show.
type ModelManagerAPI ¶
ModelManagerAPI defines the methods on the model manager API that the models command calls.
type ModelSet ¶
type ModelSet struct {
Models []UserModel `yaml:"models" json:"models"`
CurrentModel string `yaml:"current-model,omitempty" json:"current-model,omitempty"`
}
ModelSet contains the set of models known to the client, and UUID of the current model.
type ModelsSysAPI ¶
ModelsSysAPI defines the methods on the controller manager API that the list models command calls.
type ShowControllerDetails ¶
type ShowControllerDetails struct {
// Details contains the same details that client store caches for this controller.
Details ControllerDetails `yaml:"details,omitempty" json:"details,omitempty"`
// Accounts is a collection of accounts for this controller.
Accounts map[string]*AccountDetails `yaml:"accounts,omitempty" json:"accounts,omitempty"`
// CurrentAccount is the name of the current account for this controller.
CurrentAccount string `yaml:"current-account,omitempty" json:"current-account,omitempty"`
// Errors is a collection of errors related to accessing this controller details.
Errors []string `yaml:"errors,omitempty" json:"errors,omitempty"`
}
Source Files
¶
- controller.go
- createmodel.go
- destroy.go
- kill.go
- killstatus.go
- listblocks.go
- listcontrollers.go
- listcontrollersconverters.go
- listcontrollersformatters.go
- listmodels.go
- register.go
- removeblocks.go
- showcontroller.go