@Generated(value="jsii-pacmak/1.70.0 (build 03c2f6f)", date="2022-11-01T13:16:40.525Z") @Stability(value=Experimental) public interface DockerImageAssetSource extends software.amazon.jsii.JsiiSerializable
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.core.*;
DockerImageAssetSource dockerImageAssetSource = DockerImageAssetSource.builder()
.sourceHash("sourceHash")
// the properties below are optional
.directoryName("directoryName")
.dockerBuildArgs(Map.of(
"dockerBuildArgsKey", "dockerBuildArgs"))
.dockerBuildTarget("dockerBuildTarget")
.dockerFile("dockerFile")
.executable(List.of("executable"))
.networkMode("networkMode")
.platform("platform")
.repositoryName("repositoryName")
.build();
| Modifier and Type | Interface and Description |
|---|---|
static class |
DockerImageAssetSource.Builder
A builder for
DockerImageAssetSource |
static class |
DockerImageAssetSource.Jsii$Proxy
An implementation for
DockerImageAssetSource |
| Modifier and Type | Method and Description |
|---|---|
static DockerImageAssetSource.Builder |
builder() |
default String |
getDirectoryName()
(experimental) The directory where the Dockerfile is stored, must be relative to the cloud assembly root.
|
default Map<String,String> |
getDockerBuildArgs()
(experimental) Build args to pass to the `docker build` command.
|
default String |
getDockerBuildTarget()
(experimental) Docker target to build to.
|
default String |
getDockerFile()
(experimental) Path to the Dockerfile (relative to the directory).
|
default List<String> |
getExecutable()
(experimental) An external command that will produce the packaged asset.
|
default String |
getNetworkMode()
(experimental) Networking mode for the RUN commands during build.
|
default String |
getPlatform()
(experimental) Platform to build for.
|
default String |
getRepositoryName()
Deprecated.
repository name should be specified at the environment-level and not at the image level
|
String |
getSourceHash()
(experimental) The hash of the contents of the docker build context.
|
@Stability(value=Experimental) @NotNull String getSourceHash()
This hash is used throughout the system to identify this image and avoid duplicate work in case the source did not change.
NOTE: this means that if you wish to update your docker image, you must make a modification to the source (e.g. add some metadata to your Dockerfile).
@Stability(value=Experimental) @Nullable default String getDirectoryName()
Default: - Exactly one of `directoryName` and `executable` is required
@Stability(value=Experimental) @Nullable default Map<String,String> getDockerBuildArgs()
Since Docker build arguments are resolved before deployment, keys and
values cannot refer to unresolved tokens (such as lambda.functionArn or
queue.queueUrl).
Only allowed when directoryName is specified.
Default: - no build args are passed
@Stability(value=Experimental) @Nullable default String getDockerBuildTarget()
Only allowed when directoryName is specified.
Default: - no target
@Stability(value=Experimental) @Nullable default String getDockerFile()
Only allowed when directoryName is specified.
Default: - no file
@Stability(value=Experimental) @Nullable default List<String> getExecutable()
The command should produce the name of a local Docker image on stdout.
Default: - Exactly one of `directoryName` and `executable` is required
@Stability(value=Experimental) @Nullable default String getNetworkMode()
Specify this property to build images on a specific networking mode.
Default: - no networking mode specified
@Stability(value=Experimental) @Nullable default String getPlatform()
Specify this property to build images on a specific platform.
Default: - no platform specified (the current machine architecture will be used)
@Stability(value=Deprecated) @Deprecated @Nullable default String getRepositoryName()
Specify this property if you need to statically address the image, e.g. from a Kubernetes Pod. Note, this is only the repository name, without the registry and the tag parts.
Default: - automatically derived from the asset's ID.
@Stability(value=Experimental) static DockerImageAssetSource.Builder builder()
DockerImageAssetSource.Builder of DockerImageAssetSourceCopyright © 2022. All rights reserved.