We recommend new projects start with resources from the AWS provider.
aws-native.autoscaling.LifecycleHook
Explore with Pulumi AI
We recommend new projects start with resources from the AWS provider.
Resource Type definition for AWS::AutoScaling::LifecycleHook
Create LifecycleHook Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new LifecycleHook(name: string, args: LifecycleHookArgs, opts?: CustomResourceOptions);
@overload
def LifecycleHook(resource_name: str,
args: LifecycleHookArgs,
opts: Optional[ResourceOptions] = None)
@overload
def LifecycleHook(resource_name: str,
opts: Optional[ResourceOptions] = None,
auto_scaling_group_name: Optional[str] = None,
lifecycle_transition: Optional[str] = None,
default_result: Optional[str] = None,
heartbeat_timeout: Optional[int] = None,
lifecycle_hook_name: Optional[str] = None,
notification_metadata: Optional[str] = None,
notification_target_arn: Optional[str] = None,
role_arn: Optional[str] = None)
func NewLifecycleHook(ctx *Context, name string, args LifecycleHookArgs, opts ...ResourceOption) (*LifecycleHook, error)
public LifecycleHook(string name, LifecycleHookArgs args, CustomResourceOptions? opts = null)
public LifecycleHook(String name, LifecycleHookArgs args)
public LifecycleHook(String name, LifecycleHookArgs args, CustomResourceOptions options)
type: aws-native:autoscaling:LifecycleHook
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args LifecycleHookArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args LifecycleHookArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args LifecycleHookArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args LifecycleHookArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args LifecycleHookArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
LifecycleHook Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The LifecycleHook resource accepts the following input properties:
- Auto
Scaling stringGroup Name - The name of the Auto Scaling group for the lifecycle hook.
- Lifecycle
Transition string - The instance state to which you want to attach the lifecycle hook.
- Default
Result string - The action the Auto Scaling group takes when the lifecycle hook timeout elapses or if an unexpected failure occurs. The valid values are CONTINUE and ABANDON (default).
- Heartbeat
Timeout int - The maximum time, in seconds, that can elapse before the lifecycle hook times out. The range is from 30 to 7200 seconds. The default value is 3600 seconds (1 hour). If the lifecycle hook times out, Amazon EC2 Auto Scaling performs the action that you specified in the DefaultResult property.
- Lifecycle
Hook stringName - The name of the lifecycle hook.
- Notification
Metadata string - Additional information that is included any time Amazon EC2 Auto Scaling sends a message to the notification target.
- Notification
Target stringArn - The Amazon Resource Name (ARN) of the notification target that Amazon EC2 Auto Scaling uses to notify you when an instance is in the transition state for the lifecycle hook. You can specify an Amazon SQS queue or an Amazon SNS topic. The notification message includes the following information: lifecycle action token, user account ID, Auto Scaling group name, lifecycle hook name, instance ID, lifecycle transition, and notification metadata.
- Role
Arn string - The ARN of the IAM role that allows the Auto Scaling group to publish to the specified notification target, for example, an Amazon SNS topic or an Amazon SQS queue.
- Auto
Scaling stringGroup Name - The name of the Auto Scaling group for the lifecycle hook.
- Lifecycle
Transition string - The instance state to which you want to attach the lifecycle hook.
- Default
Result string - The action the Auto Scaling group takes when the lifecycle hook timeout elapses or if an unexpected failure occurs. The valid values are CONTINUE and ABANDON (default).
- Heartbeat
Timeout int - The maximum time, in seconds, that can elapse before the lifecycle hook times out. The range is from 30 to 7200 seconds. The default value is 3600 seconds (1 hour). If the lifecycle hook times out, Amazon EC2 Auto Scaling performs the action that you specified in the DefaultResult property.
- Lifecycle
Hook stringName - The name of the lifecycle hook.
- Notification
Metadata string - Additional information that is included any time Amazon EC2 Auto Scaling sends a message to the notification target.
- Notification
Target stringArn - The Amazon Resource Name (ARN) of the notification target that Amazon EC2 Auto Scaling uses to notify you when an instance is in the transition state for the lifecycle hook. You can specify an Amazon SQS queue or an Amazon SNS topic. The notification message includes the following information: lifecycle action token, user account ID, Auto Scaling group name, lifecycle hook name, instance ID, lifecycle transition, and notification metadata.
- Role
Arn string - The ARN of the IAM role that allows the Auto Scaling group to publish to the specified notification target, for example, an Amazon SNS topic or an Amazon SQS queue.
- auto
Scaling StringGroup Name - The name of the Auto Scaling group for the lifecycle hook.
- lifecycle
Transition String - The instance state to which you want to attach the lifecycle hook.
- default
Result String - The action the Auto Scaling group takes when the lifecycle hook timeout elapses or if an unexpected failure occurs. The valid values are CONTINUE and ABANDON (default).
- heartbeat
Timeout Integer - The maximum time, in seconds, that can elapse before the lifecycle hook times out. The range is from 30 to 7200 seconds. The default value is 3600 seconds (1 hour). If the lifecycle hook times out, Amazon EC2 Auto Scaling performs the action that you specified in the DefaultResult property.
- lifecycle
Hook StringName - The name of the lifecycle hook.
- notification
Metadata String - Additional information that is included any time Amazon EC2 Auto Scaling sends a message to the notification target.
- notification
Target StringArn - The Amazon Resource Name (ARN) of the notification target that Amazon EC2 Auto Scaling uses to notify you when an instance is in the transition state for the lifecycle hook. You can specify an Amazon SQS queue or an Amazon SNS topic. The notification message includes the following information: lifecycle action token, user account ID, Auto Scaling group name, lifecycle hook name, instance ID, lifecycle transition, and notification metadata.
- role
Arn String - The ARN of the IAM role that allows the Auto Scaling group to publish to the specified notification target, for example, an Amazon SNS topic or an Amazon SQS queue.
- auto
Scaling stringGroup Name - The name of the Auto Scaling group for the lifecycle hook.
- lifecycle
Transition string - The instance state to which you want to attach the lifecycle hook.
- default
Result string - The action the Auto Scaling group takes when the lifecycle hook timeout elapses or if an unexpected failure occurs. The valid values are CONTINUE and ABANDON (default).
- heartbeat
Timeout number - The maximum time, in seconds, that can elapse before the lifecycle hook times out. The range is from 30 to 7200 seconds. The default value is 3600 seconds (1 hour). If the lifecycle hook times out, Amazon EC2 Auto Scaling performs the action that you specified in the DefaultResult property.
- lifecycle
Hook stringName - The name of the lifecycle hook.
- notification
Metadata string - Additional information that is included any time Amazon EC2 Auto Scaling sends a message to the notification target.
- notification
Target stringArn - The Amazon Resource Name (ARN) of the notification target that Amazon EC2 Auto Scaling uses to notify you when an instance is in the transition state for the lifecycle hook. You can specify an Amazon SQS queue or an Amazon SNS topic. The notification message includes the following information: lifecycle action token, user account ID, Auto Scaling group name, lifecycle hook name, instance ID, lifecycle transition, and notification metadata.
- role
Arn string - The ARN of the IAM role that allows the Auto Scaling group to publish to the specified notification target, for example, an Amazon SNS topic or an Amazon SQS queue.
- auto_
scaling_ strgroup_ name - The name of the Auto Scaling group for the lifecycle hook.
- lifecycle_
transition str - The instance state to which you want to attach the lifecycle hook.
- default_
result str - The action the Auto Scaling group takes when the lifecycle hook timeout elapses or if an unexpected failure occurs. The valid values are CONTINUE and ABANDON (default).
- heartbeat_
timeout int - The maximum time, in seconds, that can elapse before the lifecycle hook times out. The range is from 30 to 7200 seconds. The default value is 3600 seconds (1 hour). If the lifecycle hook times out, Amazon EC2 Auto Scaling performs the action that you specified in the DefaultResult property.
- lifecycle_
hook_ strname - The name of the lifecycle hook.
- notification_
metadata str - Additional information that is included any time Amazon EC2 Auto Scaling sends a message to the notification target.
- notification_
target_ strarn - The Amazon Resource Name (ARN) of the notification target that Amazon EC2 Auto Scaling uses to notify you when an instance is in the transition state for the lifecycle hook. You can specify an Amazon SQS queue or an Amazon SNS topic. The notification message includes the following information: lifecycle action token, user account ID, Auto Scaling group name, lifecycle hook name, instance ID, lifecycle transition, and notification metadata.
- role_
arn str - The ARN of the IAM role that allows the Auto Scaling group to publish to the specified notification target, for example, an Amazon SNS topic or an Amazon SQS queue.
- auto
Scaling StringGroup Name - The name of the Auto Scaling group for the lifecycle hook.
- lifecycle
Transition String - The instance state to which you want to attach the lifecycle hook.
- default
Result String - The action the Auto Scaling group takes when the lifecycle hook timeout elapses or if an unexpected failure occurs. The valid values are CONTINUE and ABANDON (default).
- heartbeat
Timeout Number - The maximum time, in seconds, that can elapse before the lifecycle hook times out. The range is from 30 to 7200 seconds. The default value is 3600 seconds (1 hour). If the lifecycle hook times out, Amazon EC2 Auto Scaling performs the action that you specified in the DefaultResult property.
- lifecycle
Hook StringName - The name of the lifecycle hook.
- notification
Metadata String - Additional information that is included any time Amazon EC2 Auto Scaling sends a message to the notification target.
- notification
Target StringArn - The Amazon Resource Name (ARN) of the notification target that Amazon EC2 Auto Scaling uses to notify you when an instance is in the transition state for the lifecycle hook. You can specify an Amazon SQS queue or an Amazon SNS topic. The notification message includes the following information: lifecycle action token, user account ID, Auto Scaling group name, lifecycle hook name, instance ID, lifecycle transition, and notification metadata.
- role
Arn String - The ARN of the IAM role that allows the Auto Scaling group to publish to the specified notification target, for example, an Amazon SNS topic or an Amazon SQS queue.
Outputs
All input properties are implicitly available as output properties. Additionally, the LifecycleHook resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Package Details
- Repository
- AWS Native pulumi/pulumi-aws-native
- License
- Apache-2.0
We recommend new projects start with resources from the AWS provider.