Class: AWSCDK::ECS::CfnTaskDefinition::HostVolumePropertiesProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::ECS::CfnTaskDefinition::HostVolumePropertiesProperty
- Defined in:
- ecs/cfn_task_definition.rb
Overview
The HostVolumeProperties property specifies details on a container instance bind mount host volume.
Instance Attribute Summary collapse
-
#source_path ⇒ String?
readonly
When the
hostparameter is used, specify asourcePathto declare the path on the host container instance that's presented to the container.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(source_path: nil) ⇒ HostVolumePropertiesProperty
constructor
A new instance of HostVolumePropertiesProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(source_path: nil) ⇒ HostVolumePropertiesProperty
Returns a new instance of HostVolumePropertiesProperty.
2159 2160 2161 2162 |
# File 'ecs/cfn_task_definition.rb', line 2159 def initialize(source_path: nil) @source_path = source_path Jsii::Type.check_type(@source_path, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "sourcePath") unless @source_path.nil? end |
Instance Attribute Details
#source_path ⇒ String? (readonly)
When the host parameter is used, specify a sourcePath to declare the path on the host container instance that's presented to the container.
If this parameter is empty, then the Docker daemon has assigned a host path for you. If the host parameter contains a source_path file location, then the data volume persists at the specified location on the host container instance until you delete it manually. If the source_path value doesn't exist on the host container instance, the Docker daemon creates it. If the location does exist, the contents of the source path folder are exported.
If you're using the Fargate launch type, the source_path parameter is not supported.
2172 2173 2174 |
# File 'ecs/cfn_task_definition.rb', line 2172 def source_path @source_path end |
Class Method Details
.jsii_properties ⇒ Object
2174 2175 2176 2177 2178 |
# File 'ecs/cfn_task_definition.rb', line 2174 def self.jsii_properties { :source_path => "sourcePath", } end |
Instance Method Details
#to_jsii ⇒ Object
2180 2181 2182 2183 2184 2185 2186 |
# File 'ecs/cfn_task_definition.rb', line 2180 def to_jsii result = {} result.merge!({ "sourcePath" => @source_path, }) result.compact end |