Versions in this module Expand all Collapse all v1 v1.1.0 Mar 14, 2022 v1.0.0 Jun 3, 2021 v0 v0.9.0 Jun 23, 2020 Changes in this version + const ErrCodeFsInfoFailed + const ErrCodeNoPathDefined + const ErrCodeNotSupported + const ProvisionedVolumeName + func IsDeletedVolumeInUse(err error) bool + func IsNotSupported(err error) bool + func NewDeletedVolumeInUseError(message string) error + func NewPersistentVolumeRecyclerPodTemplate() *v1.Pod + func SetVolumeOwnership(mounter Mounter, fsGroup *int64) error + func ValidateRecyclerPodTemplate(pod *v1.Pod) error + type AttachableVolumePlugin interface + NewAttacher func() (Attacher, error) + NewDetacher func() (Detacher, error) + type Attacher interface + Attach func(spec *Spec, nodeName types.NodeName) (string, error) + VolumesAreAttached func(specs []*Spec, nodeName types.NodeName) (map[*Spec]bool, error) + WaitForAttach func(spec *Spec, devicePath string, pod *v1.Pod, timeout time.Duration) (string, error) + type Attributes struct + Managed bool + ReadOnly bool + SupportsSELinux bool + type BlockVolume interface + GetGlobalMapPath func(spec *Spec) (string, error) + GetPodDeviceMapPath func() (string, string) + type BlockVolumeMapper interface + MapDevice func(devicePath, globalMapPath, volumeMapPath, volumeMapName string, ...) error + SetUpDevice func() (string, error) + type BlockVolumePlugin interface + ConstructBlockVolumeSpec func(podUID types.UID, volumeName, mountPath string) (*Spec, error) + NewBlockVolumeMapper func(spec *Spec, podRef *v1.Pod, opts VolumeOptions) (BlockVolumeMapper, error) + NewBlockVolumeUnmapper func(name string, podUID types.UID) (BlockVolumeUnmapper, error) + type BlockVolumeUnmapper interface + TearDownDevice func(mapPath string, devicePath string) error + type BulkVolumeVerifier interface + BulkVerifyVolumes func(volumesByNode map[types.NodeName][]*Spec) (map[types.NodeName]map[*Spec]bool, error) + type DeletableVolumePlugin interface + NewDeleter func(spec *Spec) (Deleter, error) + type Deleter interface + Delete func() error + type Detacher interface + Detach func(volumeName string, nodeName types.NodeName) error + type DeviceMountableVolumePlugin interface + GetDeviceMountRefs func(deviceMountPath string) ([]string, error) + NewDeviceMounter func() (DeviceMounter, error) + NewDeviceUnmounter func() (DeviceUnmounter, error) + type DeviceMounter interface + GetDeviceMountPath func(spec *Spec) (string, error) + MountDevice func(spec *Spec, devicePath string, deviceMountPath string) error + type DeviceUnmounter interface + UnmountDevice func(deviceMountPath string) error + type DynamicPluginProber interface + Init func() error + Probe func() (events []ProbeEvent, err error) + type ExpandableVolumePlugin interface + ExpandVolumeDevice func(spec *Spec, newSize resource.Quantity, oldSize resource.Quantity) (resource.Quantity, error) + RequiresFSResize func() bool + type Metrics struct + Available *resource.Quantity + Capacity *resource.Quantity + Inodes *resource.Quantity + InodesFree *resource.Quantity + InodesUsed *resource.Quantity + Time metav1.Time + Used *resource.Quantity + type MetricsError struct + Code int + Msg string + func NewFsInfoFailedError(err error) *MetricsError + func NewNoPathDefinedError() *MetricsError + func NewNotSupportedError() *MetricsError + func (e *MetricsError) Error() string + type MetricsNil struct + func (*MetricsNil) GetMetrics() (*Metrics, error) + type MetricsProvider interface + GetMetrics func() (*Metrics, error) + func NewCachedMetrics(provider MetricsProvider) MetricsProvider + func NewMetricsDu(path string) MetricsProvider + func NewMetricsStatFS(path string) MetricsProvider + type Mounter interface + CanMount func() error + GetAttributes func() Attributes + SetUp func(fsGroup *int64) error + SetUpAt func(dir string, fsGroup *int64) error + type PersistentVolumePlugin interface + GetAccessModes func() []v1.PersistentVolumeAccessMode + type ProbeEvent struct + Op ProbeOperation + Plugin VolumePlugin + PluginName string + type ProbeOperation uint32 + const ProbeAddOrUpdate + const ProbeRemove + const VolumeParameterFSType + type ProvisionableVolumePlugin interface + NewProvisioner func(options VolumeOptions) (Provisioner, error) + type Provisioner interface + Provision func(selectedNode *v1.Node, allowedTopologies []v1.TopologySelectorTerm) (*v1.PersistentVolume, error) + type RecyclableVolumePlugin interface + Recycle func(pvName string, spec *Spec, eventRecorder recyclerclient.RecycleEventRecorder) error + type Spec struct + PersistentVolume *v1.PersistentVolume + ReadOnly bool + Volume *v1.Volume + func NewSpecFromPersistentVolume(pv *v1.PersistentVolume, readOnly bool) *Spec + func NewSpecFromVolume(vs *v1.Volume) *Spec + func (spec *Spec) Name() string + type Unmounter interface + TearDown func() error + TearDownAt func(dir string) error + type Volume interface + GetPath func() string + type VolumeConfig struct + OtherAttributes map[string]string + PVName string + ProvisioningEnabled bool + RecyclerMinimumTimeout int + RecyclerPodTemplate *v1.Pod + RecyclerTimeoutIncrement int + type VolumeHost interface + GetCSIClient func() csiclientset.Interface + GetCloudProvider func() cloudprovider.Interface + GetConfigMapFunc func() func(namespace, name string) (*v1.ConfigMap, error) + GetEventRecorder func() record.EventRecorder + GetExec func(pluginName string) mount.Exec + GetHostIP func() (net.IP, error) + GetHostName func() string + GetKubeClient func() clientset.Interface + GetMounter func(pluginName string) mount.Interface + GetNodeAllocatable func() (v1.ResourceList, error) + GetNodeLabels func() (map[string]string, error) + GetNodeName func() types.NodeName + GetPluginDir func(pluginName string) string + GetPodPluginDir func(podUID types.UID, pluginName string) string + GetPodVolumeDeviceDir func(podUID types.UID, pluginName string) string + GetPodVolumeDir func(podUID types.UID, pluginName string, volumeName string) string + GetPodsDir func() string + GetSecretFunc func() func(namespace, name string) (*v1.Secret, error) + GetServiceAccountTokenFunc func() ... + GetVolumeDevicePluginDir func(pluginName string) string + NewWrapperMounter func(volName string, spec Spec, pod *v1.Pod, opts VolumeOptions) (Mounter, error) + NewWrapperUnmounter func(volName string, spec Spec, podUID types.UID) (Unmounter, error) + type VolumeOptions struct + CloudTags *map[string]string + ClusterName string + MountOptions []string + PVC *v1.PersistentVolumeClaim + PVName string + Parameters map[string]string + PersistentVolumeReclaimPolicy v1.PersistentVolumeReclaimPolicy + type VolumePlugin interface + CanSupport func(spec *Spec) bool + ConstructVolumeSpec func(volumeName, mountPath string) (*Spec, error) + GetPluginName func() string + GetVolumeName func(spec *Spec) (string, error) + Init func(host VolumeHost) error + NewMounter func(spec *Spec, podRef *v1.Pod, opts VolumeOptions) (Mounter, error) + NewUnmounter func(name string, podUID types.UID) (Unmounter, error) + RequiresRemount func() bool + SupportsBulkVolumeVerification func() bool + SupportsMountOption func() bool + type VolumePluginMgr struct + Host VolumeHost + func (pm *VolumePluginMgr) FindAttachablePluginByName(name string) (AttachableVolumePlugin, error) + func (pm *VolumePluginMgr) FindAttachablePluginBySpec(spec *Spec) (AttachableVolumePlugin, error) + func (pm *VolumePluginMgr) FindCreatablePluginBySpec(spec *Spec) (ProvisionableVolumePlugin, error) + func (pm *VolumePluginMgr) FindDeletablePluginByName(name string) (DeletableVolumePlugin, error) + func (pm *VolumePluginMgr) FindDeletablePluginBySpec(spec *Spec) (DeletableVolumePlugin, error) + func (pm *VolumePluginMgr) FindDeviceMountablePluginByName(name string) (DeviceMountableVolumePlugin, error) + func (pm *VolumePluginMgr) FindDeviceMountablePluginBySpec(spec *Spec) (DeviceMountableVolumePlugin, error) + func (pm *VolumePluginMgr) FindExpandablePluginByName(name string) (ExpandableVolumePlugin, error) + func (pm *VolumePluginMgr) FindExpandablePluginBySpec(spec *Spec) (ExpandableVolumePlugin, error) + func (pm *VolumePluginMgr) FindMapperPluginByName(name string) (BlockVolumePlugin, error) + func (pm *VolumePluginMgr) FindMapperPluginBySpec(spec *Spec) (BlockVolumePlugin, error) + func (pm *VolumePluginMgr) FindPersistentPluginByName(name string) (PersistentVolumePlugin, error) + func (pm *VolumePluginMgr) FindPersistentPluginBySpec(spec *Spec) (PersistentVolumePlugin, error) + func (pm *VolumePluginMgr) FindPluginByName(name string) (VolumePlugin, error) + func (pm *VolumePluginMgr) FindPluginBySpec(spec *Spec) (VolumePlugin, error) + func (pm *VolumePluginMgr) FindProvisionablePluginByName(name string) (ProvisionableVolumePlugin, error) + func (pm *VolumePluginMgr) FindRecyclablePluginBySpec(spec *Spec) (RecyclableVolumePlugin, error) + func (pm *VolumePluginMgr) FindVolumePluginWithLimitsBySpec(spec *Spec) (VolumePluginWithAttachLimits, error) + func (pm *VolumePluginMgr) InitPlugins(plugins []VolumePlugin, prober DynamicPluginProber, host VolumeHost) error + func (pm *VolumePluginMgr) ListVolumePluginWithLimits() []VolumePluginWithAttachLimits + type VolumePluginWithAttachLimits interface + GetVolumeLimits func() (map[string]int64, error) + VolumeLimitKey func(spec *Spec) string