@Stability(value=Stable) public static final class AssetImage.Builder extends Object implements software.amazon.jsii.Builder<AssetImage>
AssetImage.| Modifier and Type | Method and Description |
|---|---|
AssetImage |
build() |
AssetImage.Builder |
buildArgs(Map<String,String> buildArgs)
Build args to pass to the `docker build` command.
|
static AssetImage.Builder |
create(String directory) |
AssetImage.Builder |
exclude(List<String> exclude)
File paths matching the patterns will be excluded.
|
AssetImage.Builder |
extraHash(String extraHash)
Extra information to encode into the fingerprint (e.g.
|
AssetImage.Builder |
file(String file)
Path to the Dockerfile (relative to the directory).
|
AssetImage.Builder |
followSymlinks(SymlinkFollowMode followSymlinks)
A strategy for how to handle symlinks.
|
AssetImage.Builder |
ignoreMode(IgnoreMode ignoreMode)
The ignore behavior to use for `exclude` patterns.
|
AssetImage.Builder |
invalidation(DockerImageAssetInvalidationOptions invalidation)
Options to control which parameters are used to invalidate the asset hash.
|
AssetImage.Builder |
networkMode(NetworkMode networkMode)
Networking mode for the RUN commands during build.
|
AssetImage.Builder |
platform(Platform platform)
Platform to build for.
|
AssetImage.Builder |
target(String target)
Docker target to build to.
|
@Stability(value=Stable) public static AssetImage.Builder create(String directory)
directory - The directory containing the Dockerfile. This parameter is required.AssetImage.Builder.@Stability(value=Stable) public AssetImage.Builder exclude(List<String> exclude)
See ignoreMode to set the matching behavior.
Has no effect on Assets bundled using the bundling property.
Default: - nothing is excluded
exclude - File paths matching the patterns will be excluded. This parameter is required.this@Stability(value=Stable) public AssetImage.Builder followSymlinks(SymlinkFollowMode followSymlinks)
Default: SymlinkFollowMode.NEVER
followSymlinks - A strategy for how to handle symlinks. This parameter is required.this@Stability(value=Stable) public AssetImage.Builder ignoreMode(IgnoreMode ignoreMode)
Default: IgnoreMode.GLOB
ignoreMode - The ignore behavior to use for `exclude` patterns. This parameter is required.this@Stability(value=Stable) public AssetImage.Builder extraHash(String extraHash)
Default: - hash is only based on source content
extraHash - Extra information to encode into the fingerprint (e.g. build instructions and other inputs). This parameter is required.this@Stability(value=Stable) public AssetImage.Builder buildArgs(Map<String,String> buildArgs)
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
buildArgs - Build args to pass to the `docker build` command. This parameter is required.this@Stability(value=Stable) public AssetImage.Builder file(String file)
Default: 'Dockerfile'
file - Path to the Dockerfile (relative to the directory). This parameter is required.this@Stability(value=Stable) public AssetImage.Builder invalidation(DockerImageAssetInvalidationOptions invalidation)
Default: - hash all parameters
invalidation - Options to control which parameters are used to invalidate the asset hash. This parameter is required.this@Stability(value=Stable) public AssetImage.Builder networkMode(NetworkMode networkMode)
Support docker API 1.25+.
Default: - no networking mode specified (the default networking mode `NetworkMode.DEFAULT` will be used)
networkMode - Networking mode for the RUN commands during build. This parameter is required.this@Stability(value=Stable) public AssetImage.Builder platform(Platform platform)
Requires Docker Buildx.
Default: - no platform specified (the current machine architecture will be used)
platform - Platform to build for. This parameter is required.this@Stability(value=Stable) public AssetImage.Builder target(String target)
Default: - no target
target - Docker target to build to. This parameter is required.this@Stability(value=Stable) public AssetImage build()
build in interface software.amazon.jsii.Builder<AssetImage>Copyright © 2022. All rights reserved.