DeploymentLifecycleHookTargetConfig
- class aws_cdk.aws_ecs.DeploymentLifecycleHookTargetConfig(*, lifecycle_stages, target_arn, role=None)
Bases:
object
Configuration for a deployment lifecycle hook target.
- Parameters:
lifecycle_stages (
Sequence
[DeploymentLifecycleStage
]) – The lifecycle stages when this hook should be executed.target_arn (
str
) – The ARN of the target resource.role (
Optional
[IRole
]) – The IAM role that grants permissions to invoke the target. Default: - a role will be created automatically
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk import aws_ecs as ecs from aws_cdk import aws_iam as iam # role: iam.Role deployment_lifecycle_hook_target_config = ecs.DeploymentLifecycleHookTargetConfig( lifecycle_stages=[ecs.DeploymentLifecycleStage.RECONCILE_SERVICE], target_arn="targetArn", # the properties below are optional role=role )
Attributes
- lifecycle_stages
The lifecycle stages when this hook should be executed.
- role
The IAM role that grants permissions to invoke the target.
- Default:
a role will be created automatically
- target_arn
The ARN of the target resource.