interface ContainerImageAssetMetadataEntry
Language | Type name |
---|---|
.NET | Amazon.CDK.CloudAssembly.Schema.ContainerImageAssetMetadataEntry |
Java | software.amazon.awscdk.cloudassembly.schema.ContainerImageAssetMetadataEntry |
Python | aws_cdk.cloud_assembly_schema.ContainerImageAssetMetadataEntry |
TypeScript (source) | @aws-cdk/cloud-assembly-schema » ContainerImageAssetMetadataEntry |
Metadata Entry spec for container images.
Example
const entry = {
packaging: 'container-image',
repositoryName: 'repository-name',
imageTag: 'tag',
}
Properties
Name | Type | Description |
---|---|---|
id | string | Logical identifier for the asset. |
packaging | string | Type of asset. |
path | string | Path on disk to the asset. |
source | string | The hash of the asset source. |
build | { [string]: string } | Build args to pass to the docker build command. |
build | { [string]: string } | Build secrets to pass to the docker build command. |
build | string | SSH agent socket or keys to pass to the docker build command. |
cache | boolean | Disable the cache and pass --no-cache to the docker build command. |
cache | Container [] | Cache from options to pass to the docker build command. |
cache | Container | Cache to options to pass to the docker build command. |
file? | string | Path to the Dockerfile (relative to the directory). |
image | string | ECR Repository name and repo digest (separated by "@sha256:") where this image is stored. |
image | string | The docker image tag to use for tagging pushed images. |
network | string | Networking mode for the RUN commands during build. |
outputs? | string[] | Outputs to pass to the docker build command. |
platform? | string | Platform to build for. |
repository | string | ECR repository name, if omitted a default name based on the asset's ID is used instead. |
target? | string | Docker target to build to. |
id
Type:
string
Logical identifier for the asset.
packaging
Type:
string
Type of asset.
path
Type:
string
Path on disk to the asset.
sourceHash
Type:
string
The hash of the asset source.
buildArgs?
Type:
{ [string]: string }
(optional, default: no build args are passed)
Build args to pass to the docker build
command.
buildSecrets?
Type:
{ [string]: string }
(optional, default: no build secrets are passed)
Build secrets to pass to the docker build
command.
buildSsh?
Type:
string
(optional, default: no ssh arg is passed)
SSH agent socket or keys to pass to the docker build
command.
cacheDisabled?
Type:
boolean
(optional, default: cache is used)
Disable the cache and pass --no-cache
to the docker build
command.
cacheFrom?
Type:
Container
[]
(optional, default: no cache from options are passed to the build command)
Cache from options to pass to the docker build
command.
See also: https://docs.docker.com/build/cache/backends/
cacheTo?
Type:
Container
(optional, default: no cache to options are passed to the build command)
Cache to options to pass to the docker build
command.
See also: https://docs.docker.com/build/cache/backends/
file?
Type:
string
(optional, default: no file is passed)
Path to the Dockerfile (relative to the directory).
imageNameParameter?
⚠️ Deprecated: specify repositoryName
and imageTag
instead, and then you
know where the image will go.
Type:
string
(optional, default: undefined If not specified, repositoryName
and imageTag
are
required because otherwise how will the stack know where to find the asset,
ha?)
ECR Repository name and repo digest (separated by "@sha256:") where this image is stored.
imageTag?
Type:
string
(optional, default: this parameter is REQUIRED after 1.21.0)
The docker image tag to use for tagging pushed images.
This field is
required if imageParameterName
is ommited (otherwise, the app won't be
able to find the image).
networkMode?
Type:
string
(optional, default: no networking mode specified)
Networking mode for the RUN commands during build.
outputs?
Type:
string[]
(optional, default: no outputs are passed to the build command (default outputs are used))
Outputs to pass to the docker build
command.
See also: https://docs.docker.com/engine/reference/commandline/build/#custom-build-outputs
platform?
Type:
string
(optional, default: current machine platform)
Platform to build for.
Requires Docker Buildx.
repositoryName?
Type:
string
(optional, default: this parameter is REQUIRED after 1.21.0)
ECR repository name, if omitted a default name based on the asset's ID is used instead.
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.
target?
Type:
string
(optional, default: no build target)
Docker target to build to.