Class HostVolume
java.lang.Object
software.amazon.jsii.JsiiObject
software.amazon.awscdk.services.batch.EcsVolume
software.amazon.awscdk.services.batch.HostVolume
- All Implemented Interfaces:
software.amazon.jsii.JsiiSerializable
@Generated(value="jsii-pacmak/1.119.0 (build 1634eac)",
date="2025-12-01T16:02:15.223Z")
@Stability(Stable)
public class HostVolume
extends EcsVolume
Creates a Host volume.
This volume will persist on the host at the specified hostPath.
If the hostPath is not specified, Docker will choose the host path. In this case,
the data may not persist after the containers that use it stop running.
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.batch.*;
HostVolume hostVolume = HostVolume.Builder.create()
.containerPath("containerPath")
.name("name")
// the properties below are optional
.hostPath("hostPath")
.readonly(false)
.build();
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode -
Constructor Summary
ConstructorsModifierConstructorDescriptionHostVolume(HostVolumeOptions options) protectedHostVolume(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedHostVolume(software.amazon.jsii.JsiiObjectRef objRef) -
Method Summary
Modifier and TypeMethodDescriptionThe path on the host machine this container will have access to.static Booleanreturnstrueifxis aHostVolume,falseotherwise.Methods inherited from class software.amazon.awscdk.services.batch.EcsVolume
efs, getContainerPath, getName, getReadonly, hostMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Constructor Details
-
HostVolume
protected HostVolume(software.amazon.jsii.JsiiObjectRef objRef) -
HostVolume
protected HostVolume(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
HostVolume
- Parameters:
options- This parameter is required.
-
-
Method Details
-
isHostVolume
returnstrueifxis aHostVolume,falseotherwise.- Parameters:
x- This parameter is required.
-
getHostPath
The path on the host machine this container will have access to.
-