Documentation ¶
Index ¶
- type BundledCluster
- func (bc *BundledCluster) Get(client *rancher.Client) (cluster *BundledCluster, err error)
- func (bc *BundledCluster) ListAvailableVersions(client *rancher.Client) (versions []string, err error)
- func (bc *BundledCluster) Update(client *rancher.Client, cUpdates *BundledCluster) (updatedCluster *BundledCluster, err error)
- func (bc *BundledCluster) UpdateKubernetesVersion(client *rancher.Client, versionToUpgrade *string) (updatedCluster *BundledCluster, err error)
- func (bc *BundledCluster) UpdateNodepoolKubernetesVersions(client *rancher.Client, versionToUpgrade *string) (updatedCluster *BundledCluster, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BundledCluster ¶
type BundledCluster struct { Meta *clusters.ClusterMeta V1 *v1.SteveAPIObject V3 *v3.Cluster }
BundledCluster is a struct that can contain different cluster version types and the meta of the cluster:
- Meta is a ClusterMeta value of cluster's meta.
- V1 is a v1 type cluster value of the cluster.
- V3 is a v3 type cluster value of the cluster.
func NewWithClusterMeta ¶
func NewWithClusterMeta(cmeta *clusters.ClusterMeta) (cluster *BundledCluster, err error)
NewWithClusterMeta is a constructor to initialize a BundledCluster. It returns cluster meta struct and error if any. Cluster v1 and v3 versions can't store value at the same time.
func (*BundledCluster) Get ¶
func (bc *BundledCluster) Get(client *rancher.Client) (cluster *BundledCluster, err error)
Get is a method of BundledCluster that uses provisioning and management clients to get related cluster data depending on cluster version.
func (*BundledCluster) ListAvailableVersions ¶
func (bc *BundledCluster) ListAvailableVersions(client *rancher.Client) (versions []string, err error)
ListAvailable is a method of BundledCluster that uses list available functions depending on cluster's provider information. Returns versions as slice of strings and error if any.
func (*BundledCluster) Update ¶
func (bc *BundledCluster) Update(client *rancher.Client, cUpdates *BundledCluster) (updatedCluster *BundledCluster, err error)
Update is a method of BundledCluster that uses provisioning and management clients to update related cluster data depending on cluster version.
func (*BundledCluster) UpdateKubernetesVersion ¶
func (bc *BundledCluster) UpdateKubernetesVersion(client *rancher.Client, versionToUpgrade *string) (updatedCluster *BundledCluster, err error)
UpdateKubernetesVersion is a method of BundledCluster that uses update method of BundledCluster depending on cluster's provider information. Returns updated BundledCluster and error if any.
func (*BundledCluster) UpdateNodepoolKubernetesVersions ¶
func (bc *BundledCluster) UpdateNodepoolKubernetesVersions(client *rancher.Client, versionToUpgrade *string) (updatedCluster *BundledCluster, err error)
UpdateNodePoolKubernetesVersions is a method of BundledCluster that uses update method of BundledCluster depending on cluster's provider information. Returns updated BundledCluster and error if any.