Class NetworkMode
java.lang.Object
software.amazon.jsii.JsiiObject
software.amazon.awscdk.services.ecr.assets.NetworkMode
- All Implemented Interfaces:
software.amazon.jsii.JsiiSerializable
@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)",
date="2023-06-19T16:30:37.988Z")
@Stability(Stable)
public class NetworkMode
extends software.amazon.jsii.JsiiObject
networking mode on build time supported by docker.
Example:
import software.amazon.awscdk.services.ecr.assets.DockerImageAsset; import software.amazon.awscdk.services.ecr.assets.NetworkMode; DockerImageAsset asset = DockerImageAsset.Builder.create(this, "MyBuildImage") .directory(join(__dirname, "my-image")) .networkMode(NetworkMode.HOST) .build();
-
Nested Class Summary
Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode
-
Field Summary
Modifier and TypeFieldDescriptionstatic final NetworkMode
The default networking mode if omitted, create a network stack on the default Docker bridge.static final NetworkMode
Use the Docker host network stack.static final NetworkMode
Disable the network stack, only the loopback device will be created. -
Constructor Summary
ModifierConstructorDescriptionprotected
NetworkMode
(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protected
NetworkMode
(software.amazon.jsii.JsiiObjectRef objRef) -
Method Summary
Modifier and TypeMethodDescriptionstatic NetworkMode
Used to specify a custom networking mode Use this if the networking mode name is not yet supported by the CDK.static NetworkMode
fromContainer
(String containerId) Reuse another container's network stack.getMode()
The networking mode to use for docker build.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
-
Field Details
-
DEFAULT
The default networking mode if omitted, create a network stack on the default Docker bridge. -
HOST
Use the Docker host network stack. -
NONE
Disable the network stack, only the loopback device will be created.
-
-
Constructor Details
-
NetworkMode
protected NetworkMode(software.amazon.jsii.JsiiObjectRef objRef) -
NetworkMode
protected NetworkMode(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
-
-
Method Details
-
custom
Used to specify a custom networking mode Use this if the networking mode name is not yet supported by the CDK.- Parameters:
mode
- The networking mode to use for docker build. This parameter is required.
-
fromContainer
Reuse another container's network stack.- Parameters:
containerId
- The target container's id or name. This parameter is required.
-
getMode
The networking mode to use for docker build.
-