Alibaba Cloud

Pulumi Official
Package maintained by Pulumi
v3.21.0 published on Tuesday, Jun 14, 2022 by Pulumi

LifecycleHook

Import

Ess lifecycle hook can be imported using the id, e.g.

 $ pulumi import alicloud:ess/lifecycleHook:LifecycleHook example ash-l12345

Create a LifecycleHook Resource

new LifecycleHook(name: string, args: LifecycleHookArgs, opts?: CustomResourceOptions);
@overload
def LifecycleHook(resource_name: str,
                  opts: Optional[ResourceOptions] = None,
                  default_result: Optional[str] = None,
                  heartbeat_timeout: Optional[int] = None,
                  lifecycle_transition: Optional[str] = None,
                  name: Optional[str] = None,
                  notification_arn: Optional[str] = None,
                  notification_metadata: Optional[str] = None,
                  scaling_group_id: Optional[str] = None)
@overload
def LifecycleHook(resource_name: str,
                  args: LifecycleHookArgs,
                  opts: Optional[ResourceOptions] = 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: alicloud:ess:LifecycleHook
properties: # The arguments to resource properties.
options: # 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.
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:

LifecycleTransition string

Type of Scaling activity attached to lifecycle hook. Supported value: SCALE_OUT, SCALE_IN.

ScalingGroupId string

The ID of the Auto Scaling group to which you want to assign the lifecycle hook.

DefaultResult string

Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, default value: CONTINUE.

HeartbeatTimeout int

Defines the amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the action defined in the default_result parameter. Default value: 600.

Name string

The name of the lifecycle hook, which must contain 2-64 characters (English or Chinese), starting with numbers, English letters or Chinese characters, and can contain number, underscores _, hypens -, and decimal point .. If this parameter value is not specified, the default value is lifecycle hook id.

NotificationArn string

The Arn of notification target.

NotificationMetadata string

Additional information that you want to include when Auto Scaling sends a message to the notification target.

LifecycleTransition string

Type of Scaling activity attached to lifecycle hook. Supported value: SCALE_OUT, SCALE_IN.

ScalingGroupId string

The ID of the Auto Scaling group to which you want to assign the lifecycle hook.

DefaultResult string

Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, default value: CONTINUE.

HeartbeatTimeout int

Defines the amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the action defined in the default_result parameter. Default value: 600.

Name string

The name of the lifecycle hook, which must contain 2-64 characters (English or Chinese), starting with numbers, English letters or Chinese characters, and can contain number, underscores _, hypens -, and decimal point .. If this parameter value is not specified, the default value is lifecycle hook id.

NotificationArn string

The Arn of notification target.

NotificationMetadata string

Additional information that you want to include when Auto Scaling sends a message to the notification target.

lifecycleTransition String

Type of Scaling activity attached to lifecycle hook. Supported value: SCALE_OUT, SCALE_IN.

scalingGroupId String

The ID of the Auto Scaling group to which you want to assign the lifecycle hook.

defaultResult String

Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, default value: CONTINUE.

heartbeatTimeout Integer

Defines the amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the action defined in the default_result parameter. Default value: 600.

name String

The name of the lifecycle hook, which must contain 2-64 characters (English or Chinese), starting with numbers, English letters or Chinese characters, and can contain number, underscores _, hypens -, and decimal point .. If this parameter value is not specified, the default value is lifecycle hook id.

notificationArn String

The Arn of notification target.

notificationMetadata String

Additional information that you want to include when Auto Scaling sends a message to the notification target.

lifecycleTransition string

Type of Scaling activity attached to lifecycle hook. Supported value: SCALE_OUT, SCALE_IN.

scalingGroupId string

The ID of the Auto Scaling group to which you want to assign the lifecycle hook.

defaultResult string

Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, default value: CONTINUE.

heartbeatTimeout number

Defines the amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the action defined in the default_result parameter. Default value: 600.

name string

The name of the lifecycle hook, which must contain 2-64 characters (English or Chinese), starting with numbers, English letters or Chinese characters, and can contain number, underscores _, hypens -, and decimal point .. If this parameter value is not specified, the default value is lifecycle hook id.

notificationArn string

The Arn of notification target.

notificationMetadata string

Additional information that you want to include when Auto Scaling sends a message to the notification target.

lifecycle_transition str

Type of Scaling activity attached to lifecycle hook. Supported value: SCALE_OUT, SCALE_IN.

scaling_group_id str

The ID of the Auto Scaling group to which you want to assign the lifecycle hook.

default_result str

Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, default value: CONTINUE.

heartbeat_timeout int

Defines the amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the action defined in the default_result parameter. Default value: 600.

name str

The name of the lifecycle hook, which must contain 2-64 characters (English or Chinese), starting with numbers, English letters or Chinese characters, and can contain number, underscores _, hypens -, and decimal point .. If this parameter value is not specified, the default value is lifecycle hook id.

notification_arn str

The Arn of notification target.

notification_metadata str

Additional information that you want to include when Auto Scaling sends a message to the notification target.

lifecycleTransition String

Type of Scaling activity attached to lifecycle hook. Supported value: SCALE_OUT, SCALE_IN.

scalingGroupId String

The ID of the Auto Scaling group to which you want to assign the lifecycle hook.

defaultResult String

Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, default value: CONTINUE.

heartbeatTimeout Number

Defines the amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the action defined in the default_result parameter. Default value: 600.

name String

The name of the lifecycle hook, which must contain 2-64 characters (English or Chinese), starting with numbers, English letters or Chinese characters, and can contain number, underscores _, hypens -, and decimal point .. If this parameter value is not specified, the default value is lifecycle hook id.

notificationArn String

The Arn of notification target.

notificationMetadata String

Additional information that you want to include when Auto Scaling sends a message to the notification target.

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.

Look up an Existing LifecycleHook Resource

Get an existing LifecycleHook resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: LifecycleHookState, opts?: CustomResourceOptions): LifecycleHook
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        default_result: Optional[str] = None,
        heartbeat_timeout: Optional[int] = None,
        lifecycle_transition: Optional[str] = None,
        name: Optional[str] = None,
        notification_arn: Optional[str] = None,
        notification_metadata: Optional[str] = None,
        scaling_group_id: Optional[str] = None) -> LifecycleHook
func GetLifecycleHook(ctx *Context, name string, id IDInput, state *LifecycleHookState, opts ...ResourceOption) (*LifecycleHook, error)
public static LifecycleHook Get(string name, Input<string> id, LifecycleHookState? state, CustomResourceOptions? opts = null)
public static LifecycleHook get(String name, Output<String> id, LifecycleHookState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
DefaultResult string

Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, default value: CONTINUE.

HeartbeatTimeout int

Defines the amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the action defined in the default_result parameter. Default value: 600.

LifecycleTransition string

Type of Scaling activity attached to lifecycle hook. Supported value: SCALE_OUT, SCALE_IN.

Name string

The name of the lifecycle hook, which must contain 2-64 characters (English or Chinese), starting with numbers, English letters or Chinese characters, and can contain number, underscores _, hypens -, and decimal point .. If this parameter value is not specified, the default value is lifecycle hook id.

NotificationArn string

The Arn of notification target.

NotificationMetadata string

Additional information that you want to include when Auto Scaling sends a message to the notification target.

ScalingGroupId string

The ID of the Auto Scaling group to which you want to assign the lifecycle hook.

DefaultResult string

Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, default value: CONTINUE.

HeartbeatTimeout int

Defines the amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the action defined in the default_result parameter. Default value: 600.

LifecycleTransition string

Type of Scaling activity attached to lifecycle hook. Supported value: SCALE_OUT, SCALE_IN.

Name string

The name of the lifecycle hook, which must contain 2-64 characters (English or Chinese), starting with numbers, English letters or Chinese characters, and can contain number, underscores _, hypens -, and decimal point .. If this parameter value is not specified, the default value is lifecycle hook id.

NotificationArn string

The Arn of notification target.

NotificationMetadata string

Additional information that you want to include when Auto Scaling sends a message to the notification target.

ScalingGroupId string

The ID of the Auto Scaling group to which you want to assign the lifecycle hook.

defaultResult String

Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, default value: CONTINUE.

heartbeatTimeout Integer

Defines the amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the action defined in the default_result parameter. Default value: 600.

lifecycleTransition String

Type of Scaling activity attached to lifecycle hook. Supported value: SCALE_OUT, SCALE_IN.

name String

The name of the lifecycle hook, which must contain 2-64 characters (English or Chinese), starting with numbers, English letters or Chinese characters, and can contain number, underscores _, hypens -, and decimal point .. If this parameter value is not specified, the default value is lifecycle hook id.

notificationArn String

The Arn of notification target.

notificationMetadata String

Additional information that you want to include when Auto Scaling sends a message to the notification target.

scalingGroupId String

The ID of the Auto Scaling group to which you want to assign the lifecycle hook.

defaultResult string

Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, default value: CONTINUE.

heartbeatTimeout number

Defines the amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the action defined in the default_result parameter. Default value: 600.

lifecycleTransition string

Type of Scaling activity attached to lifecycle hook. Supported value: SCALE_OUT, SCALE_IN.

name string

The name of the lifecycle hook, which must contain 2-64 characters (English or Chinese), starting with numbers, English letters or Chinese characters, and can contain number, underscores _, hypens -, and decimal point .. If this parameter value is not specified, the default value is lifecycle hook id.

notificationArn string

The Arn of notification target.

notificationMetadata string

Additional information that you want to include when Auto Scaling sends a message to the notification target.

scalingGroupId string

The ID of the Auto Scaling group to which you want to assign the lifecycle hook.

default_result str

Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, default value: CONTINUE.

heartbeat_timeout int

Defines the amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the action defined in the default_result parameter. Default value: 600.

lifecycle_transition str

Type of Scaling activity attached to lifecycle hook. Supported value: SCALE_OUT, SCALE_IN.

name str

The name of the lifecycle hook, which must contain 2-64 characters (English or Chinese), starting with numbers, English letters or Chinese characters, and can contain number, underscores _, hypens -, and decimal point .. If this parameter value is not specified, the default value is lifecycle hook id.

notification_arn str

The Arn of notification target.

notification_metadata str

Additional information that you want to include when Auto Scaling sends a message to the notification target.

scaling_group_id str

The ID of the Auto Scaling group to which you want to assign the lifecycle hook.

defaultResult String

Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, default value: CONTINUE.

heartbeatTimeout Number

Defines the amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the action defined in the default_result parameter. Default value: 600.

lifecycleTransition String

Type of Scaling activity attached to lifecycle hook. Supported value: SCALE_OUT, SCALE_IN.

name String

The name of the lifecycle hook, which must contain 2-64 characters (English or Chinese), starting with numbers, English letters or Chinese characters, and can contain number, underscores _, hypens -, and decimal point .. If this parameter value is not specified, the default value is lifecycle hook id.

notificationArn String

The Arn of notification target.

notificationMetadata String

Additional information that you want to include when Auto Scaling sends a message to the notification target.

scalingGroupId String

The ID of the Auto Scaling group to which you want to assign the lifecycle hook.

Package Details

Repository
https://github.com/pulumi/pulumi-alicloud
License
Apache-2.0
Notes

This Pulumi package is based on the alicloud Terraform Provider.