Class PodVolume
- java.lang.Object
-
- hudson.model.AbstractDescribableImpl<PodVolume>
-
- org.csanchez.jenkins.plugins.kubernetes.volumes.PodVolume
-
- All Implemented Interfaces:
Describable<PodVolume>
,Serializable
- Direct Known Subclasses:
ConfigMapVolume
,DynamicPVCVolume
,EmptyDirVolume
,HostPathVolume
,NfsVolume
,PersistentVolumeClaim
,PodVolumes.PodVolume
,SecretVolume
public abstract class PodVolume extends AbstractDescribableImpl<PodVolume> implements Serializable
Base class for all Kubernetes volume types- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description PodVolume()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Deprecated Methods Modifier and Type Method Description io.fabric8.kubernetes.api.model.Volume
buildVolume(String volumeName)
Deprecated.io.fabric8.kubernetes.api.model.Volume
buildVolume(String volumeName, String podName)
It's expected to override at least one ofbuildVolume(String, String)
orbuildVolume(String)
.io.fabric8.kubernetes.api.model.PersistentVolumeClaim
createVolume(io.fabric8.kubernetes.client.KubernetesClient client, io.fabric8.kubernetes.api.model.ObjectMeta podMetaData)
Creates a volume claim.abstract String
getMountPath()
static boolean
podVolumeExists(String path, List<PodVolume> existingVolumes)
static boolean
volumeMountExists(String path, Iterable<io.fabric8.kubernetes.api.model.VolumeMount> existingMounts)
-
Methods inherited from class hudson.model.AbstractDescribableImpl
getDescriptor
-
-
-
-
Method Detail
-
getMountPath
public abstract String getMountPath()
-
buildVolume
public io.fabric8.kubernetes.api.model.Volume buildVolume(String volumeName, String podName)
It's expected to override at least one ofbuildVolume(String, String)
orbuildVolume(String)
.- Parameters:
volumeName
- The name of the volume to build.- Returns:
- The built volume.
-
buildVolume
@Deprecated public io.fabric8.kubernetes.api.model.Volume buildVolume(String volumeName)
Deprecated.It's expected to override at least one ofbuildVolume(String, String)
orbuildVolume(String)
.- Parameters:
volumeName
- The name of the volume to build.- Returns:
- The built volume.
-
createVolume
public io.fabric8.kubernetes.api.model.PersistentVolumeClaim createVolume(io.fabric8.kubernetes.client.KubernetesClient client, io.fabric8.kubernetes.api.model.ObjectMeta podMetaData)
Creates a volume claim.- Parameters:
client
- Kubernetes clientpodMetaData
- Kubernetes pod metadata- Returns:
- the created volume claim
-
podVolumeExists
public static boolean podVolumeExists(String path, List<PodVolume> existingVolumes)
-
-