alicloud.ess.LifecycleHook
Import
Ess lifecycle hook can be imported using the id, e.g.
$ pulumi import alicloud:ess/lifecycleHook:LifecycleHook example ash-l12345
Create 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:
- Lifecycle
Transition string Type of Scaling activity attached to lifecycle hook. Supported value: SCALE_OUT, SCALE_IN.
- Scaling
Group stringId The ID of the Auto Scaling group to which you want to assign the lifecycle hook.
- Default
Result string Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, ROLLBACK, 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 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.- Notification
Arn string The Arn of notification target.
- Notification
Metadata string Additional information that you want to include when Auto Scaling sends a message to the notification target.
- Lifecycle
Transition string Type of Scaling activity attached to lifecycle hook. Supported value: SCALE_OUT, SCALE_IN.
- Scaling
Group stringId The ID of the Auto Scaling group to which you want to assign the lifecycle hook.
- Default
Result string Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, ROLLBACK, 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 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.- Notification
Arn string The Arn of notification target.
- Notification
Metadata string Additional information that you want to include when Auto Scaling sends a message to the notification target.
- lifecycle
Transition String Type of Scaling activity attached to lifecycle hook. Supported value: SCALE_OUT, SCALE_IN.
- scaling
Group StringId The ID of the Auto Scaling group to which you want to assign the lifecycle hook.
- default
Result String Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, ROLLBACK, default value: CONTINUE.
- heartbeat
Timeout 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.- notification
Arn String The Arn of notification target.
- notification
Metadata String Additional information that you want to include when Auto Scaling sends a message to the notification target.
- lifecycle
Transition string Type of Scaling activity attached to lifecycle hook. Supported value: SCALE_OUT, SCALE_IN.
- scaling
Group stringId The ID of the Auto Scaling group to which you want to assign the lifecycle hook.
- default
Result string Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, ROLLBACK, default value: CONTINUE.
- heartbeat
Timeout 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.- notification
Arn string The Arn of notification target.
- notification
Metadata 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_ strid 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, ROLLBACK, 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.
- lifecycle
Transition String Type of Scaling activity attached to lifecycle hook. Supported value: SCALE_OUT, SCALE_IN.
- scaling
Group StringId The ID of the Auto Scaling group to which you want to assign the lifecycle hook.
- default
Result String Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, ROLLBACK, default value: CONTINUE.
- heartbeat
Timeout 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.- notification
Arn String The Arn of notification target.
- notification
Metadata 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 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.
- Default
Result string Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, ROLLBACK, 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 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.- Notification
Arn string The Arn of notification target.
- Notification
Metadata string Additional information that you want to include when Auto Scaling sends a message to the notification target.
- Scaling
Group stringId The ID of the Auto Scaling group to which you want to assign the lifecycle hook.
- Default
Result string Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, ROLLBACK, 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 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.- Notification
Arn string The Arn of notification target.
- Notification
Metadata string Additional information that you want to include when Auto Scaling sends a message to the notification target.
- Scaling
Group stringId The ID of the Auto Scaling group to which you want to assign the lifecycle hook.
- default
Result String Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, ROLLBACK, default value: CONTINUE.
- heartbeat
Timeout 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.
- lifecycle
Transition 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.- notification
Arn String The Arn of notification target.
- notification
Metadata String Additional information that you want to include when Auto Scaling sends a message to the notification target.
- scaling
Group StringId The ID of the Auto Scaling group to which you want to assign the lifecycle hook.
- default
Result string Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, ROLLBACK, default value: CONTINUE.
- heartbeat
Timeout 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.
- lifecycle
Transition 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.- notification
Arn string The Arn of notification target.
- notification
Metadata string Additional information that you want to include when Auto Scaling sends a message to the notification target.
- scaling
Group stringId 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, ROLLBACK, 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_ strid The ID of the Auto Scaling group to which you want to assign the lifecycle hook.
- default
Result String Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses. Applicable value: CONTINUE, ABANDON, ROLLBACK, default value: CONTINUE.
- heartbeat
Timeout 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.
- lifecycle
Transition 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.- notification
Arn String The Arn of notification target.
- notification
Metadata String Additional information that you want to include when Auto Scaling sends a message to the notification target.
- scaling
Group StringId The ID of the Auto Scaling group to which you want to assign the lifecycle hook.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
alicloud
Terraform Provider.