Class ContainerImageAssetMetadataEntry
Metadata Entry spec for container images.
Inheritance
Implements
Namespace: Amazon.CDK.CloudAssembly.Schema
Assembly: Amazon.CDK.CloudAssembly.Schema.dll
Syntax (csharp)
public class ContainerImageAssetMetadataEntry : Object, IContainerImageAssetMetadataEntry
Syntax (vb)
Public Class ContainerImageAssetMetadataEntry
Inherits Object
Implements IContainerImageAssetMetadataEntry
Remarks
ExampleMetadata: fixture=_generated
Examples
// Example automatically generated from non-compiling source. May contain errors.
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.CloudAssembly.Schema;
var containerImageAssetMetadataEntry = new ContainerImageAssetMetadataEntry {
Id = "id",
Packaging = "packaging",
Path = "path",
SourceHash = "sourceHash",
// the properties below are optional
BuildArgs = new Dictionary<string, string> {
{ "buildArgsKey", "buildArgs" }
},
File = "file",
ImageNameParameter = "imageNameParameter",
ImageTag = "imageTag",
NetworkMode = "networkMode",
Platform = "platform",
RepositoryName = "repositoryName",
Target = "target"
};
Synopsis
Constructors
ContainerImageAssetMetadataEntry() |
Properties
BuildArgs | Build args to pass to the |
File | Path to the Dockerfile (relative to the directory). |
Id | Logical identifier for the asset. |
ImageNameParameter | (deprecated) ECR Repository name and repo digest (separated by "@sha256:") where this image is stored. |
ImageTag | The docker image tag to use for tagging pushed images. |
NetworkMode | Networking mode for the RUN commands during build. |
Packaging | Type of asset. |
Path | Path on disk to the asset. |
Platform | Platform to build for. |
RepositoryName | ECR repository name, if omitted a default name based on the asset's ID is used instead. |
SourceHash | The hash of the asset source. |
Target | Docker target to build to. |
Constructors
ContainerImageAssetMetadataEntry()
public ContainerImageAssetMetadataEntry()
Properties
BuildArgs
Build args to pass to the docker build
command.
public IDictionary<string, string> BuildArgs { get; set; }
Property Value
System.Collections.Generic.IDictionary<System.String, System.String>
Remarks
Default: no build args are passed
File
Path to the Dockerfile (relative to the directory).
public string File { get; set; }
Property Value
System.String
Remarks
Default: - no file is passed
Id
Logical identifier for the asset.
public string Id { get; set; }
Property Value
System.String
ImageNameParameter
(deprecated) ECR Repository name and repo digest (separated by "@sha256:") where this image is stored.
public string ImageNameParameter { get; set; }
Property Value
System.String
Remarks
Default: undefined If not specified, repositoryName
and imageTag
are
required because otherwise how will the stack know where to find the asset,
ha?
Stability: Deprecated
ImageTag
The docker image tag to use for tagging pushed images.
public string ImageTag { get; set; }
Property Value
System.String
Remarks
This field is
required if imageParameterName
is ommited (otherwise, the app won't be
able to find the image).
Default: - this parameter is REQUIRED after 1.21.0
NetworkMode
Networking mode for the RUN commands during build.
public string NetworkMode { get; set; }
Property Value
System.String
Remarks
Default: - no networking mode specified
Packaging
Type of asset.
public string Packaging { get; set; }
Property Value
System.String
Path
Path on disk to the asset.
public string Path { get; set; }
Property Value
System.String
Platform
Platform to build for.
public string Platform { get; set; }
Property Value
System.String
Remarks
Requires Docker Buildx.
Default: - current machine platform
RepositoryName
ECR repository name, if omitted a default name based on the asset's ID is used instead.
public string RepositoryName { get; set; }
Property Value
System.String
Remarks
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: - this parameter is REQUIRED after 1.21.0
SourceHash
The hash of the asset source.
public string SourceHash { get; set; }
Property Value
System.String
Target
Docker target to build to.
public string Target { get; set; }
Property Value
System.String
Remarks
Default: no build target