Class ContainerDefinitionOptions
Properties to define a ContainerDefinition.
Inheritance
Implements
Namespace: Amazon.CDK.AWS.StepFunctions.Tasks
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class ContainerDefinitionOptions : Object, IContainerDefinitionOptions
Syntax (vb)
Public Class ContainerDefinitionOptions
Inherits Object
Implements IContainerDefinitionOptions
Remarks
See: https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_ContainerDefinition.html
ExampleMetadata: infused
Examples
new SageMakerCreateModel(this, "Sagemaker", new SageMakerCreateModelProps {
ModelName = "MyModel",
PrimaryContainer = new ContainerDefinition(new ContainerDefinitionOptions {
Image = DockerImage.FromJsonExpression(JsonPath.StringAt("$.Model.imageName")),
Mode = Mode.SINGLE_MODEL,
ModelS3Location = S3Location.FromJsonExpression("$.TrainingJob.ModelArtifacts.S3ModelArtifacts")
})
});
Synopsis
Constructors
ContainerDefinitionOptions() |
Properties
ContainerHostName | This parameter is ignored for models that contain only a PrimaryContainer. |
EnvironmentVariables | The environment variables to set in the Docker container. |
Image | The Amazon EC2 Container Registry (Amazon ECR) path where inference code is stored. |
Mode | Defines how many models the container hosts. |
ModelPackageName | The name or Amazon Resource Name (ARN) of the model package to use to create the model. |
ModelS3Location | The S3 path where the model artifacts, which result from model training, are stored. |
Constructors
ContainerDefinitionOptions()
public ContainerDefinitionOptions()
Properties
ContainerHostName
This parameter is ignored for models that contain only a PrimaryContainer.
public string ContainerHostName { get; set; }
Property Value
System.String
Remarks
When a ContainerDefinition is part of an inference pipeline, the value of the parameter uniquely identifies the container for the purposes of logging and metrics.
Default: - None
EnvironmentVariables
The environment variables to set in the Docker container.
public TaskInput EnvironmentVariables { get; set; }
Property Value
Remarks
Default: - No variables
Image
The Amazon EC2 Container Registry (Amazon ECR) path where inference code is stored.
public DockerImage Image { get; set; }
Property Value
Remarks
Default: - None
Mode
Defines how many models the container hosts.
public Nullable<Mode> Mode { get; set; }
Property Value
System.Nullable<Mode>
Remarks
Default: - Mode.SINGLE_MODEL
ModelPackageName
The name or Amazon Resource Name (ARN) of the model package to use to create the model.
public string ModelPackageName { get; set; }
Property Value
System.String
Remarks
Default: - None
ModelS3Location
The S3 path where the model artifacts, which result from model training, are stored.
public S3Location ModelS3Location { get; set; }
Property Value
Remarks
This path must point to a single gzip compressed tar archive (.tar.gz suffix). The S3 path is required for Amazon SageMaker built-in algorithms, but not if you use your own algorithms.
Default: - None