openebs

package
v2.8.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2020 License: Apache-2.0, Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrK8SApiAccountNotSet = errors.New("k8s api service-account is not setup")

ErrK8SApiAccountNotSet is returned when the account used to talk to k8s api is not setup

View Source
var (
	// SnapSupportedCASType is a map of supported volume type for snapshot
	// operations.
	SnapSupportedCASType = map[string]bool{
		"jiva":  true,
		"cstor": true,
	}
)

Functions

func CreateCloneVolumeSpec

func CreateCloneVolumeSpec(snapshotData *crdv1.VolumeSnapshotData,
	pvc *v1.PersistentVolumeClaim,
	pvName string,
) (vol v1alpha1.CASVolume,
	class string)

CreateVolumeSpec constructs the volumeSpec for volume create request

func GetK8sClient

func GetK8sClient() (*kubernetes.Clientset, error)

GetK8sClient instantiates a k8s client

func GetMayaService

func GetMayaService() error

func GetNameAndNameSpaceFromSnapshotName

func GetNameAndNameSpaceFromSnapshotName(name string) (string, string, error)

GetNameAndNameSpaceFromSnapshotName retrieves the namespace and the short name of a snapshot from its full name, for exmaple "test-ns/snap1"

func GetPersistentVolumeClass

func GetPersistentVolumeClass(volume *v1.PersistentVolume) string

GetPersistentVolumeClass returns StorageClassName

func GetPluginName

func GetPluginName() string

GetPluginName gets the name of the volume plugin

func GetStorageClass

func GetStorageClass(pvName string) (string, error)

GetPersistentClass returns StoragClassName

func RegisterPlugin

func RegisterPlugin() volume.Plugin

RegisterPlugin registers the volume plugin

Types

This section is empty.

Jump to

Keyboard shortcuts

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