@Generated(value="jsii-pacmak/1.58.0 (build f8ba112)", date="2022-05-11T19:24:29.093Z") @Stability(value=Experimental) public class NetworkMode extends software.amazon.jsii.JsiiObject
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();
| Modifier and Type | Field and Description |
|---|---|
static NetworkMode |
DEFAULT
(experimental) The default networking mode if omitted, create a network stack on the default Docker bridge.
|
static NetworkMode |
HOST
(experimental) Use the Docker host network stack.
|
static NetworkMode |
NONE
(experimental) Disable the network stack, only the loopback device will be created.
|
| Modifier | Constructor and Description |
|---|---|
protected |
NetworkMode(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
NetworkMode(software.amazon.jsii.JsiiObjectRef objRef) |
| Modifier and Type | Method and Description |
|---|---|
static NetworkMode |
custom(String mode)
(experimental) 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)
(experimental) Reuse another container's network stack.
|
String |
getMode()
(experimental) The networking mode to use for docker build.
|
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet@Stability(value=Experimental) public static final NetworkMode DEFAULT
@Stability(value=Experimental) public static final NetworkMode HOST
@Stability(value=Experimental) public static final NetworkMode NONE
protected NetworkMode(software.amazon.jsii.JsiiObjectRef objRef)
protected NetworkMode(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Experimental) @NotNull public static NetworkMode custom(@NotNull String mode)
mode - The networking mode to use for docker build. This parameter is required.@Stability(value=Experimental) @NotNull public static NetworkMode fromContainer(@NotNull String containerId)
containerId - The target container's id or name. This parameter is required.@Stability(value=Experimental) @NotNull public String getMode()
Copyright © 2022. All rights reserved.