Class: AWSCDK::StepFunctionsTasks::ContainerDefinitionOptions
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::StepFunctionsTasks::ContainerDefinitionOptions
- Defined in:
- step_functions_tasks/container_definition_options.rb
Overview
Properties to define a ContainerDefinition.
Instance Attribute Summary collapse
-
#container_host_name ⇒ String?
readonly
This parameter is ignored for models that contain only a PrimaryContainer.
-
#environment_variables ⇒ AWSCDK::StepFunctions::TaskInput?
readonly
The environment variables to set in the Docker container.
-
#image ⇒ AWSCDK::StepFunctionsTasks::DockerImage?
readonly
The Amazon EC2 Container Registry (Amazon ECR) path where inference code is stored.
-
#mode ⇒ AWSCDK::StepFunctionsTasks::Mode?
readonly
Defines how many models the container hosts.
-
#model_package_name ⇒ String?
readonly
The name or Amazon Resource Name (ARN) of the model package to use to create the model.
-
#model_s3_location ⇒ AWSCDK::StepFunctionsTasks::S3Location?
readonly
The S3 path where the model artifacts, which result from model training, are stored.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(container_host_name: nil, environment_variables: nil, image: nil, mode: nil, model_package_name: nil, model_s3_location: nil) ⇒ ContainerDefinitionOptions
constructor
A new instance of ContainerDefinitionOptions.
- #to_jsii ⇒ Object
Constructor Details
#initialize(container_host_name: nil, environment_variables: nil, image: nil, mode: nil, model_package_name: nil, model_s3_location: nil) ⇒ ContainerDefinitionOptions
Returns a new instance of ContainerDefinitionOptions.
15 16 17 18 19 20 21 22 23 24 25 26 27 28 |
# File 'step_functions_tasks/container_definition_options.rb', line 15 def initialize(container_host_name: nil, environment_variables: nil, image: nil, mode: nil, model_package_name: nil, model_s3_location: nil) @container_host_name = container_host_name Jsii::Type.check_type(@container_host_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "containerHostName") unless @container_host_name.nil? @environment_variables = environment_variables Jsii::Type.check_type(@environment_variables, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3Nfc3RlcGZ1bmN0aW9ucy5UYXNrSW5wdXQifQ==")), "environmentVariables") unless @environment_variables.nil? @image = image Jsii::Type.check_type(@image, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3Nfc3RlcGZ1bmN0aW9uc190YXNrcy5Eb2NrZXJJbWFnZSJ9")), "image") unless @image.nil? @mode = mode Jsii::Type.check_type(@mode, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3Nfc3RlcGZ1bmN0aW9uc190YXNrcy5Nb2RlIn0=")), "mode") unless @mode.nil? @model_package_name = model_package_name Jsii::Type.check_type(@model_package_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "modelPackageName") unless @model_package_name.nil? @model_s3_location = model_s3_location Jsii::Type.check_type(@model_s3_location, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3Nfc3RlcGZ1bmN0aW9uc190YXNrcy5TM0xvY2F0aW9uIn0=")), "modelS3Location") unless @model_s3_location.nil? end |
Instance Attribute Details
#container_host_name ⇒ String? (readonly)
Default: - None
This parameter is ignored for models that contain only a PrimaryContainer.
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.
37 38 39 |
# File 'step_functions_tasks/container_definition_options.rb', line 37 def container_host_name @container_host_name end |
#environment_variables ⇒ AWSCDK::StepFunctions::TaskInput? (readonly)
Default: - No variables
The environment variables to set in the Docker container.
42 43 44 |
# File 'step_functions_tasks/container_definition_options.rb', line 42 def environment_variables @environment_variables end |
#image ⇒ AWSCDK::StepFunctionsTasks::DockerImage? (readonly)
Default: - None
The Amazon EC2 Container Registry (Amazon ECR) path where inference code is stored.
47 48 49 |
# File 'step_functions_tasks/container_definition_options.rb', line 47 def image @image end |
#mode ⇒ AWSCDK::StepFunctionsTasks::Mode? (readonly)
Default: - Mode.SINGLE_MODEL
Defines how many models the container hosts.
52 53 54 |
# File 'step_functions_tasks/container_definition_options.rb', line 52 def mode @mode end |
#model_package_name ⇒ String? (readonly)
Default: - None
The name or Amazon Resource Name (ARN) of the model package to use to create the model.
57 58 59 |
# File 'step_functions_tasks/container_definition_options.rb', line 57 def model_package_name @model_package_name end |
#model_s3_location ⇒ AWSCDK::StepFunctionsTasks::S3Location? (readonly)
Default: - None
The S3 path where the model artifacts, which result from model training, are stored.
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.
65 66 67 |
# File 'step_functions_tasks/container_definition_options.rb', line 65 def model_s3_location @model_s3_location end |
Class Method Details
.jsii_properties ⇒ Object
67 68 69 70 71 72 73 74 75 76 |
# File 'step_functions_tasks/container_definition_options.rb', line 67 def self.jsii_properties { :container_host_name => "containerHostName", :environment_variables => "environmentVariables", :image => "image", :mode => "mode", :model_package_name => "modelPackageName", :model_s3_location => "modelS3Location", } end |
Instance Method Details
#to_jsii ⇒ Object
78 79 80 81 82 83 84 85 86 87 88 89 |
# File 'step_functions_tasks/container_definition_options.rb', line 78 def to_jsii result = {} result.merge!({ "containerHostName" => @container_host_name, "environmentVariables" => @environment_variables, "image" => @image, "mode" => @mode, "modelPackageName" => @model_package_name, "modelS3Location" => @model_s3_location, }) result.compact end |