Package org.cdk8s.plus24
Class AzureDiskPersistentVolume.Builder
- java.lang.Object
-
- org.cdk8s.plus24.AzureDiskPersistentVolume.Builder
-
- All Implemented Interfaces:
software.amazon.jsii.Builder<AzureDiskPersistentVolume>
- Enclosing class:
- AzureDiskPersistentVolume
@Stability(Stable) public static final class AzureDiskPersistentVolume.Builder extends Object implements software.amazon.jsii.Builder<AzureDiskPersistentVolume>
A fluent builder forAzureDiskPersistentVolume
.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description AzureDiskPersistentVolume.Builder
accessModes(List<? extends PersistentVolumeAccessMode> accessModes)
Contains all ways the volume can be mounted.AzureDiskPersistentVolume
build()
AzureDiskPersistentVolume.Builder
cachingMode(AzureDiskPersistentVolumeCachingMode cachingMode)
Host Caching mode.AzureDiskPersistentVolume.Builder
claim(IPersistentVolumeClaim claim)
Part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim.static AzureDiskPersistentVolume.Builder
create(software.constructs.Construct scope, String id)
AzureDiskPersistentVolume.Builder
diskName(String diskName)
The Name of the data disk in the blob storage.AzureDiskPersistentVolume.Builder
diskUri(String diskUri)
The URI the data disk in the blob storage.AzureDiskPersistentVolume.Builder
fsType(String fsType)
Filesystem type to mount.AzureDiskPersistentVolume.Builder
kind(AzureDiskPersistentVolumeKind kind)
Kind of disk.AzureDiskPersistentVolume.Builder
metadata(org.cdk8s.ApiObjectMetadata metadata)
Metadata that all persisted resources must have, which includes all objects users must create.AzureDiskPersistentVolume.Builder
mountOptions(List<String> mountOptions)
A list of mount options, e.g.AzureDiskPersistentVolume.Builder
readOnly(Boolean readOnly)
Force the ReadOnly setting in VolumeMounts.AzureDiskPersistentVolume.Builder
reclaimPolicy(PersistentVolumeReclaimPolicy reclaimPolicy)
When a user is done with their volume, they can delete the PVC objects from the API that allows reclamation of the resource.AzureDiskPersistentVolume.Builder
storage(org.cdk8s.Size storage)
What is the storage capacity of this volume.AzureDiskPersistentVolume.Builder
storageClassName(String storageClassName)
Name of StorageClass to which this persistent volume belongs.AzureDiskPersistentVolume.Builder
volumeMode(PersistentVolumeMode volumeMode)
Defines what type of volume is required by the claim.
-
-
-
Method Detail
-
create
@Stability(Stable) public static AzureDiskPersistentVolume.Builder create(software.constructs.Construct scope, String id)
- Parameters:
scope
- This parameter is required.id
- This parameter is required.- Returns:
- a new instance of
AzureDiskPersistentVolume.Builder
.
-
metadata
@Stability(Stable) public AzureDiskPersistentVolume.Builder metadata(org.cdk8s.ApiObjectMetadata metadata)
Metadata that all persisted resources must have, which includes all objects users must create.- Parameters:
metadata
- Metadata that all persisted resources must have, which includes all objects users must create. This parameter is required.- Returns:
this
-
accessModes
@Stability(Stable) public AzureDiskPersistentVolume.Builder accessModes(List<? extends PersistentVolumeAccessMode> accessModes)
Contains all ways the volume can be mounted.Default: - No access modes.
- Parameters:
accessModes
- Contains all ways the volume can be mounted. This parameter is required.- Returns:
this
- See Also:
- https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes
-
claim
@Stability(Stable) public AzureDiskPersistentVolume.Builder claim(IPersistentVolumeClaim claim)
Part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim.Expected to be non-nil when bound.
Default: - Not bound to a specific claim.
- Parameters:
claim
- Part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim. This parameter is required.- Returns:
this
- See Also:
- https://kubernetes.io/docs/concepts/storage/persistent-volumes#binding
-
mountOptions
@Stability(Stable) public AzureDiskPersistentVolume.Builder mountOptions(List<String> mountOptions)
A list of mount options, e.g. ["ro", "soft"]. Not validated - mount will simply fail if one is invalid.Default: - No options.
- Parameters:
mountOptions
- A list of mount options, e.g. ["ro", "soft"]. Not validated - mount will simply fail if one is invalid. This parameter is required.- Returns:
this
- See Also:
- https://kubernetes.io/docs/concepts/storage/persistent-volumes/#mount-options
-
reclaimPolicy
@Stability(Stable) public AzureDiskPersistentVolume.Builder reclaimPolicy(PersistentVolumeReclaimPolicy reclaimPolicy)
When a user is done with their volume, they can delete the PVC objects from the API that allows reclamation of the resource.The reclaim policy tells the cluster what to do with the volume after it has been released of its claim.
Default: PersistentVolumeReclaimPolicy.RETAIN
- Parameters:
reclaimPolicy
- When a user is done with their volume, they can delete the PVC objects from the API that allows reclamation of the resource. This parameter is required.- Returns:
this
- See Also:
- https://kubernetes.io/docs/concepts/storage/persistent-volumes#reclaiming
-
storage
@Stability(Stable) public AzureDiskPersistentVolume.Builder storage(org.cdk8s.Size storage)
What is the storage capacity of this volume.Default: - No specified.
- Parameters:
storage
- What is the storage capacity of this volume. This parameter is required.- Returns:
this
- See Also:
- https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources
-
storageClassName
@Stability(Stable) public AzureDiskPersistentVolume.Builder storageClassName(String storageClassName)
Name of StorageClass to which this persistent volume belongs.Default: - Volume does not belong to any storage class.
- Parameters:
storageClassName
- Name of StorageClass to which this persistent volume belongs. This parameter is required.- Returns:
this
-
volumeMode
@Stability(Stable) public AzureDiskPersistentVolume.Builder volumeMode(PersistentVolumeMode volumeMode)
Defines what type of volume is required by the claim.Default: VolumeMode.FILE_SYSTEM
- Parameters:
volumeMode
- Defines what type of volume is required by the claim. This parameter is required.- Returns:
this
-
diskName
@Stability(Stable) public AzureDiskPersistentVolume.Builder diskName(String diskName)
The Name of the data disk in the blob storage.- Parameters:
diskName
- The Name of the data disk in the blob storage. This parameter is required.- Returns:
this
-
diskUri
@Stability(Stable) public AzureDiskPersistentVolume.Builder diskUri(String diskUri)
The URI the data disk in the blob storage.- Parameters:
diskUri
- The URI the data disk in the blob storage. This parameter is required.- Returns:
this
-
cachingMode
@Stability(Stable) public AzureDiskPersistentVolume.Builder cachingMode(AzureDiskPersistentVolumeCachingMode cachingMode)
Host Caching mode.Default: - AzureDiskPersistentVolumeCachingMode.NONE.
- Parameters:
cachingMode
- Host Caching mode. This parameter is required.- Returns:
this
-
fsType
@Stability(Stable) public AzureDiskPersistentVolume.Builder fsType(String fsType)
Filesystem type to mount.Must be a filesystem type supported by the host operating system.
Default: 'ext4'
- Parameters:
fsType
- Filesystem type to mount. This parameter is required.- Returns:
this
-
kind
@Stability(Stable) public AzureDiskPersistentVolume.Builder kind(AzureDiskPersistentVolumeKind kind)
Kind of disk.Default: AzureDiskPersistentVolumeKind.SHARED
- Parameters:
kind
- Kind of disk. This parameter is required.- Returns:
this
-
readOnly
@Stability(Stable) public AzureDiskPersistentVolume.Builder readOnly(Boolean readOnly)
Force the ReadOnly setting in VolumeMounts.Default: false
- Parameters:
readOnly
- Force the ReadOnly setting in VolumeMounts. This parameter is required.- Returns:
this
-
build
@Stability(Stable) public AzureDiskPersistentVolume build()
- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<AzureDiskPersistentVolume>
-
-