Class EksVolume
java.lang.Object
software.amazon.jsii.JsiiObject
software.amazon.awscdk.services.batch.EksVolume
- All Implemented Interfaces:
software.amazon.jsii.JsiiSerializable
- Direct Known Subclasses:
EmptyDirVolume
,HostPathVolume
,SecretPathVolume
@Generated(value="jsii-pacmak/1.104.0 (build e79254c)",
date="2024-11-22T02:23:57.700Z")
@Stability(Stable)
public abstract class EksVolume
extends software.amazon.jsii.JsiiObject
A Volume that can be mounted to a container supported by EKS.
Example:
EksJobDefinition jobDefn = EksJobDefinition.Builder.create(this, "eksf2") .container(EksContainerDefinition.Builder.create(this, "container") .image(ContainerImage.fromRegistry("amazon/amazon-ecs-sample")) .volumes(List.of(EksVolume.emptyDir(EmptyDirVolumeOptions.builder() .name("myEmptyDirVolume") .mountPath("/mount/path") .medium(EmptyDirMediumType.MEMORY) .readonly(true) .sizeLimit(Size.mebibytes(2048)) .build()))) .build()) .build();
-
Nested Class Summary
Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode
-
Constructor Summary
ModifierConstructorDescriptionprotected
EksVolume
(EksVolumeOptions options) protected
EksVolume
(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protected
EksVolume
(software.amazon.jsii.JsiiObjectRef objRef) -
Method Summary
Modifier and TypeMethodDescriptionstatic EmptyDirVolume
emptyDir
(EmptyDirVolumeOptions options) Creates a Kubernetes EmptyDir volume.The path on the container where the container is mounted.getName()
The name of this volume.If specified, the container has readonly access to the volume.static HostPathVolume
hostPath
(HostPathVolumeOptions options) Creates a Kubernetes HostPath volume.static SecretPathVolume
secret
(SecretPathVolumeOptions options) Creates a Kubernetes Secret volume.Methods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Constructor Details
-
EksVolume
protected EksVolume(software.amazon.jsii.JsiiObjectRef objRef) -
EksVolume
protected EksVolume(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
EksVolume
- Parameters:
options
- This parameter is required.
-
-
Method Details
-
emptyDir
@Stability(Stable) @NotNull public static EmptyDirVolume emptyDir(@NotNull EmptyDirVolumeOptions options) Creates a Kubernetes EmptyDir volume.- Parameters:
options
- This parameter is required.- See Also:
-
hostPath
@Stability(Stable) @NotNull public static HostPathVolume hostPath(@NotNull HostPathVolumeOptions options) Creates a Kubernetes HostPath volume.- Parameters:
options
- This parameter is required.- See Also:
-
secret
@Stability(Stable) @NotNull public static SecretPathVolume secret(@NotNull SecretPathVolumeOptions options) Creates a Kubernetes Secret volume.- Parameters:
options
- This parameter is required.- See Also:
-
getName
The name of this volume.The name must be a valid DNS subdomain name.
- See Also:
-
getContainerPath
The path on the container where the container is mounted.Default: - the container is not mounted
-
getReadonly
If specified, the container has readonly access to the volume.Otherwise, the container has read/write access.
Default: false
-