Documentation
¶
Index ¶
- type Cluster
- type ClusterAction
- type ClusterConfiguration
- type ClusterCreate
- type ClusterKubeConfig
- type ClusterList
- type ClusterPerformAction
- type ClusterService
- func (c ClusterService) Create(ctx context.Context, body ClusterCreate) (order common.Ordering, err error)
- func (c ClusterService) Delete(ctx context.Context, id int) (err error)
- func (c ClusterService) Get(ctx context.Context, id int) (cluster Cluster, err error)
- func (c ClusterService) GetConfiguration(ctx context.Context, id int) (config ClusterConfiguration, err error)
- func (c ClusterService) GetKubeConfig(ctx context.Context, id int) (kubeConfig ClusterKubeConfig, err error)
- func (c ClusterService) List(ctx context.Context, cursor goclient.Cursor) (list ClusterList, err error)
- func (c ClusterService) LoadBalancers(clusterID int) LoadBalancerService
- func (c ClusterService) Nodes(clusterID int) NodeService
- func (c ClusterService) PerformAction(ctx context.Context, id int, body ClusterPerformAction) (cluster Cluster, err error)
- func (c ClusterService) Update(ctx context.Context, id int, body ClusterUpdate) (cluster Cluster, err error)
- func (c ClusterService) UpdateConfiguration(ctx context.Context, id int, body ClusterConfiguration) (config ClusterConfiguration, err error)
- func (c ClusterService) UpdateFlavor(ctx context.Context, id int, body ClusterUpdateFlavor) (cluster Cluster, err error)
- func (c ClusterService) Volumes(clusterID int) VolumeService
- type ClusterStatus
- type ClusterUpdate
- type ClusterUpdateFlavor
- type ClusterVersion
- type ClusterWorkerCreate
- type ClusterWorkerUpdate
- type LoadBalancer
- type LoadBalancerList
- type LoadBalancerService
- type Node
- type NodeAction
- type NodeList
- type NodePerformAction
- type NodeRole
- type NodeService
- type NodeStatus
- type Volume
- type VolumeList
- type VolumeService
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cluster ¶
type Cluster struct {
ID int `json:"id"`
Name string `json:"name"`
Location common.Location `json:"location"`
Product common.Product `json:"product"`
Network compute.Network `json:"network"`
SecurityGroup compute.SecurityGroup `json:"security_group"`
PublicAddress string `json:"public_address"`
DNSName string `json:"dns_name"`
NodeCount struct {
Current struct {
ControlPlane int `json:"control-plane"`
Worker int `json:"worker"`
} `json:"current"`
Expected struct {
ControlPlane int `json:"control-plane"`
Worker int `json:"worker"`
} `json:"expected"`
} `json:"node_count"`
ExpectedPreset struct {
ControlPlane common.Product `json:"control_plane"`
Worker common.Product `json:"worker"`
} `json:"expected_preset"`
Version ClusterVersion `json:"kubernetes_version"`
Status ClusterStatus `json:"status"`
Locked bool `json:"locked"`
KubeConfig struct {
UpdatedAt common.Time `json:"updated_at"`
ExpiresAt common.Time `json:"expires_at"`
} `json:"kube_config"`
}
type ClusterAction ¶
type ClusterConfiguration ¶
type ClusterConfiguration struct {
VersionID int `json:"version_id"`
Variables json.RawMessage `json:"variables"`
}
type ClusterCreate ¶
type ClusterCreate struct {
Name string `json:"name"`
LocationID int `json:"location_id"`
NetworkID int `json:"network_id"`
Worker ClusterWorkerCreate `json:"worker"`
AttachExternalIP bool `json:"attach_external_ip"`
}
type ClusterKubeConfig ¶
type ClusterKubeConfig struct {
KubeConfig string `json:"kube_config"`
}
type ClusterList ¶
type ClusterList struct {
Items []Cluster
Pagination goclient.Pagination
}
type ClusterPerformAction ¶
type ClusterPerformAction struct {
Action string `json:"action"`
}
type ClusterService ¶
type ClusterService struct {
// contains filtered or unexported fields
}
func NewClusterService ¶
func NewClusterService(client goclient.Client) ClusterService
func (ClusterService) Create ¶
func (c ClusterService) Create(ctx context.Context, body ClusterCreate) (order common.Ordering, err error)
func (ClusterService) Delete ¶
func (c ClusterService) Delete(ctx context.Context, id int) (err error)
func (ClusterService) GetConfiguration ¶
func (c ClusterService) GetConfiguration(ctx context.Context, id int) (config ClusterConfiguration, err error)
func (ClusterService) GetKubeConfig ¶
func (c ClusterService) GetKubeConfig(ctx context.Context, id int) (kubeConfig ClusterKubeConfig, err error)
func (ClusterService) List ¶
func (c ClusterService) List(ctx context.Context, cursor goclient.Cursor) (list ClusterList, err error)
func (ClusterService) LoadBalancers ¶
func (c ClusterService) LoadBalancers(clusterID int) LoadBalancerService
func (ClusterService) Nodes ¶
func (c ClusterService) Nodes(clusterID int) NodeService
func (ClusterService) PerformAction ¶
func (c ClusterService) PerformAction(ctx context.Context, id int, body ClusterPerformAction) (cluster Cluster, err error)
func (ClusterService) Update ¶
func (c ClusterService) Update(ctx context.Context, id int, body ClusterUpdate) (cluster Cluster, err error)
func (ClusterService) UpdateConfiguration ¶
func (c ClusterService) UpdateConfiguration(ctx context.Context, id int, body ClusterConfiguration) (config ClusterConfiguration, err error)
func (ClusterService) UpdateFlavor ¶
func (c ClusterService) UpdateFlavor(ctx context.Context, id int, body ClusterUpdateFlavor) (cluster Cluster, err error)
func (ClusterService) Volumes ¶
func (c ClusterService) Volumes(clusterID int) VolumeService
type ClusterStatus ¶
type ClusterStatus struct {
ID int `json:"id"`
Key string `json:"key"`
Name string `json:"name"`
Actions []ClusterAction `json:"actions"`
}
type ClusterUpdate ¶
type ClusterUpdate struct {
Name string `json:"name,omitempty"`
}
type ClusterUpdateFlavor ¶
type ClusterUpdateFlavor struct {
Worker ClusterWorkerUpdate `json:"worker"`
}
type ClusterVersion ¶
type ClusterVersion struct {
ID int `json:"id"`
Name string `json:"name"`
Major int `json:"major"`
Minor int `json:"minor"`
Schema json.RawMessage `json:"schema"`
UpgradePaths []ClusterVersion `json:"upgrade_paths"`
HostImage compute.Image `json:"host_image"`
}
type ClusterWorkerCreate ¶
type ClusterWorkerUpdate ¶
type LoadBalancer ¶
type LoadBalancer = compute.LoadBalancer
type LoadBalancerList ¶
type LoadBalancerList = compute.LoadBalancerList
type LoadBalancerService ¶
type LoadBalancerService struct {
// contains filtered or unexported fields
}
func NewLoadBalancerService ¶
func NewLoadBalancerService(client goclient.Client, clusterID int) LoadBalancerService
func (LoadBalancerService) List ¶
func (v LoadBalancerService) List(ctx context.Context, cursor goclient.Cursor) (list LoadBalancerList, err error)
type Node ¶
type Node struct {
ID int `json:"id"`
Name string `json:"name"`
Roles []NodeRole `json:"roles"`
Product common.Product `json:"product"`
Network compute.ServerNetworkAttachment `json:"network"`
Status NodeStatus `json:"status"`
}
type NodeAction ¶
type NodeList ¶
type NodeList struct {
Items []Node
Pagination goclient.Pagination
}
type NodePerformAction ¶
type NodePerformAction struct {
Action string `json:"action"`
}
type NodeService ¶
type NodeService struct {
// contains filtered or unexported fields
}
func NewNodeService ¶
func NewNodeService(client goclient.Client, clusterID int) NodeService
func (NodeService) PerformAction ¶
func (n NodeService) PerformAction(ctx context.Context, id int, body NodePerformAction) (node Node, err error)
type NodeStatus ¶
type NodeStatus struct {
ID int `json:"id"`
Key string `json:"key"`
Name string `json:"name"`
Actions []NodeAction `json:"actions"`
}
type VolumeList ¶
type VolumeList = compute.VolumeList
type VolumeService ¶
type VolumeService struct {
// contains filtered or unexported fields
}
func NewVolumeService ¶
func NewVolumeService(client goclient.Client, clusterID int) VolumeService
func (VolumeService) Delete ¶
func (v VolumeService) Delete(ctx context.Context, id int) (err error)
func (VolumeService) List ¶
func (v VolumeService) List(ctx context.Context, cursor goclient.Cursor) (list VolumeList, err error)
Click to show internal directories.
Click to hide internal directories.