@Generated(value="jsii-pacmak/1.73.0 (build 6faeda3)", date="2023-01-31T18:36:52.255Z") public interface DockerImageAssetOptions extends FingerprintOptions, FileFingerprintOptions
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import software.amazon.awscdk.assets.*; import software.amazon.awscdk.services.ecr.assets.*; import software.amazon.awscdk.core.*; NetworkMode networkMode; Platform platform; DockerImageAssetOptions dockerImageAssetOptions = DockerImageAssetOptions.builder() .buildArgs(Map.of( "buildArgsKey", "buildArgs")) .exclude(List.of("exclude")) .extraHash("extraHash") .file("file") .follow(FollowMode.NEVER) .followSymlinks(SymlinkFollowMode.NEVER) .ignoreMode(IgnoreMode.GLOB) .invalidation(DockerImageAssetInvalidationOptions.builder() .buildArgs(false) .extraHash(false) .file(false) .networkMode(false) .platform(false) .repositoryName(false) .target(false) .build()) .networkMode(networkMode) .platform(platform) .repositoryName("repositoryName") .target("target") .build();
Modifier and Type | Interface and Description |
---|---|
static class |
DockerImageAssetOptions.Builder
A builder for
DockerImageAssetOptions |
static class |
DockerImageAssetOptions.Jsii$Proxy
An implementation for
DockerImageAssetOptions |
Modifier and Type | Method and Description |
---|---|
static DockerImageAssetOptions.Builder |
builder() |
default java.util.Map<java.lang.String,java.lang.String> |
getBuildArgs()
Build args to pass to the `docker build` command.
|
default java.util.List<java.lang.String> |
getExclude()
Deprecated.
|
default java.lang.String |
getExtraHash()
Deprecated.
|
default java.lang.String |
getFile()
Path to the Dockerfile (relative to the directory).
|
default IgnoreMode |
getIgnoreMode()
Deprecated.
|
default DockerImageAssetInvalidationOptions |
getInvalidation()
Options to control which parameters are used to invalidate the asset hash.
|
default NetworkMode |
getNetworkMode()
Networking mode for the RUN commands during build.
|
default Platform |
getPlatform()
Platform to build for.
|
default java.lang.String |
getRepositoryName()
Deprecated.
to control the location of docker image assets, please override
`Stack.addDockerImageAsset`. this feature will be removed in future
releases.
|
default java.lang.String |
getTarget()
Docker target to build to.
|
getFollow
getFollowSymlinks
default java.util.Map<java.lang.String,java.lang.String> getBuildArgs()
Since Docker build arguments are resolved before deployment, keys and
values cannot refer to unresolved tokens (such as lambda.functionArn
or
queue.queueUrl
).
Default: - no build args are passed
default java.lang.String getFile()
Default: 'Dockerfile'
default DockerImageAssetInvalidationOptions getInvalidation()
Default: - hash all parameters
default NetworkMode getNetworkMode()
Support docker API 1.25+.
Default: - no networking mode specified (the default networking mode `NetworkMode.DEFAULT` will be used)
default Platform getPlatform()
Requires Docker Buildx.
Default: - no platform specified (the current machine architecture will be used)
@Deprecated default java.lang.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: - the default ECR repository for CDK assets
default java.lang.String getTarget()
Default: - no target
@Deprecated default java.lang.String getExtraHash()
Default: - hash is only based on source content
getExtraHash
in interface FileFingerprintOptions
getExtraHash
in interface FingerprintOptions
@Deprecated default java.util.List<java.lang.String> getExclude()
Default: nothing is excluded
getExclude
in interface CopyOptions
getExclude
in interface FileCopyOptions
@Deprecated default IgnoreMode getIgnoreMode()
Default: - GLOB for file assets, DOCKER or GLOB for docker assets depending on whether the '
getIgnoreMode
in interface CopyOptions
getIgnoreMode
in interface FileCopyOptions
static DockerImageAssetOptions.Builder builder()
builder
in interface CopyOptions
builder
in interface FileCopyOptions
builder
in interface FileFingerprintOptions
builder
in interface FingerprintOptions
DockerImageAssetOptions.Builder
of DockerImageAssetOptions