Class: AWSCDK::ECS::DeploymentLifecycleHookTargetConfig
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::ECS::DeploymentLifecycleHookTargetConfig
- Defined in:
- ecs/deployment_lifecycle_hook_target_config.rb
Overview
Configuration for a deployment lifecycle hook target.
Instance Attribute Summary collapse
-
#lifecycle_stages ⇒ Array<AWSCDK::ECS::DeploymentLifecycleStage>
readonly
The lifecycle stages when this hook should be executed.
-
#role ⇒ AWSCDK::IAM::IRole?
readonly
The IAM role that grants permissions to invoke the target.
-
#target_arn ⇒ String
readonly
The ARN of the target resource.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(lifecycle_stages:, target_arn:, role: nil) ⇒ DeploymentLifecycleHookTargetConfig
constructor
A new instance of DeploymentLifecycleHookTargetConfig.
- #to_jsii ⇒ Object
Constructor Details
#initialize(lifecycle_stages:, target_arn:, role: nil) ⇒ DeploymentLifecycleHookTargetConfig
Returns a new instance of DeploymentLifecycleHookTargetConfig.
10 11 12 13 14 15 16 17 |
# File 'ecs/deployment_lifecycle_hook_target_config.rb', line 10 def initialize(lifecycle_stages:, target_arn:, role: nil) @lifecycle_stages = lifecycle_stages Jsii::Type.check_type(@lifecycle_stages, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7ImZxbiI6ImF3cy1jZGstbGliLmF3c19lY3MuRGVwbG95bWVudExpZmVjeWNsZVN0YWdlIn0sImtpbmQiOiJhcnJheSJ9fQ==")), "lifecycleStages") @target_arn = target_arn Jsii::Type.check_type(@target_arn, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "targetArn") @role = role Jsii::Type.check_type(@role, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfaWFtLklSb2xlIn0=")), "role") unless @role.nil? end |
Instance Attribute Details
#lifecycle_stages ⇒ Array<AWSCDK::ECS::DeploymentLifecycleStage> (readonly)
The lifecycle stages when this hook should be executed.
22 23 24 |
# File 'ecs/deployment_lifecycle_hook_target_config.rb', line 22 def lifecycle_stages @lifecycle_stages end |
#role ⇒ AWSCDK::IAM::IRole? (readonly)
Note:
Default: - a role will be created automatically
The IAM role that grants permissions to invoke the target.
31 32 33 |
# File 'ecs/deployment_lifecycle_hook_target_config.rb', line 31 def role @role end |
#target_arn ⇒ String (readonly)
The ARN of the target resource.
26 27 28 |
# File 'ecs/deployment_lifecycle_hook_target_config.rb', line 26 def target_arn @target_arn end |
Class Method Details
.jsii_properties ⇒ Object
33 34 35 36 37 38 39 |
# File 'ecs/deployment_lifecycle_hook_target_config.rb', line 33 def self.jsii_properties { :lifecycle_stages => "lifecycleStages", :target_arn => "targetArn", :role => "role", } end |
Instance Method Details
#to_jsii ⇒ Object
41 42 43 44 45 46 47 48 49 |
# File 'ecs/deployment_lifecycle_hook_target_config.rb', line 41 def to_jsii result = {} result.merge!({ "lifecycleStages" => @lifecycle_stages, "targetArn" => @target_arn, "role" => @role, }) result.compact end |