storageoscluster

package
v2.1.0+incompatible Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 24, 2020 License: MIT Imports: 24 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Add

func Add(mgr manager.Manager) error

Add creates a new StorageOSCluster Controller and adds it to the Manager. The Manager will set fields on the Controller and Start it when the Manager is Started.

Types

type Deployment added in v0.0.12

type Deployment interface {
	// Deploy deploys a cluster.
	Deploy() error
	// Delete deletes a deployed cluster.
	Delete() error
}

Deployment is an interface for deployment of a cluster.

type ReconcileStorageOSCluster

type ReconcileStorageOSCluster struct {
	// contains filtered or unexported fields
}

ReconcileStorageOSCluster reconciles a StorageOSCluster object

func (*ReconcileStorageOSCluster) Reconcile

Reconcile reads that state of the cluster for a StorageOSCluster object and makes changes based on the state read and what is in the StorageOSCluster.Spec The Controller will requeue the Request to be processed again if the returned error is non-nil or Result.Requeue is true, otherwise upon completion it will remove the work from the queue.

func (*ReconcileStorageOSCluster) ResetCurrentCluster

func (r *ReconcileStorageOSCluster) ResetCurrentCluster()

ResetCurrentCluster resets the current cluster of the controller.

func (*ReconcileStorageOSCluster) SetCurrentCluster

func (r *ReconcileStorageOSCluster) SetCurrentCluster(cluster *storageosv1.StorageOSCluster)

SetCurrentCluster sets the currently active cluster in the controller.

func (*ReconcileStorageOSCluster) UpdateCurrentCluster

func (r *ReconcileStorageOSCluster) UpdateCurrentCluster(cluster *storageosv1.StorageOSCluster) error

UpdateCurrentCluster checks if there are any existing cluster and updates the current cluster with the new cluster is no existing cluster is found.

type StorageOSCluster added in v0.0.12

type StorageOSCluster struct {
	// contains filtered or unexported fields
}

StorageOSCluster stores the current cluster's information. It binds the cluster and the deployment together, ensuring deployment interacts with the right cluster resource.

func NewStorageOSCluster added in v0.0.12

func NewStorageOSCluster(cluster *storageosv1.StorageOSCluster) *StorageOSCluster

NewStorageOSCluster creates a new StorageOSCluster object.

func (*StorageOSCluster) DeleteDeployment added in v0.0.12

func (c *StorageOSCluster) DeleteDeployment(r *ReconcileStorageOSCluster) error

DeleteDeployment deletes the StorageOS Cluster deployment.

func (*StorageOSCluster) Deploy added in v0.0.12

Deploy deploys the StorageOS cluster.

func (*StorageOSCluster) IsCurrentCluster added in v0.0.12

func (c *StorageOSCluster) IsCurrentCluster(cluster *storageosv1.StorageOSCluster) bool

IsCurrentCluster compares the cluster attributes to check if the given cluster is the same as the current cluster.

func (*StorageOSCluster) SetDeployment added in v0.0.12

func (c *StorageOSCluster) SetDeployment(r *ReconcileStorageOSCluster)

SetDeployment creates a new StorageOS Deployment and sets it for the current StorageOSCluster.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL