Skip to main content

instance_healths

Creates, updates, deletes, gets or lists an instance_healths resource.

Overview

Nameinstance_healths
TypeResource
Idaws.autoscaling.instance_healths

Fields

The following fields are returned by SELECT queries:

SELECT not supported for this resource, use SHOW METHODS to view available operations for the resource.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
set_instance_healthupdateInstanceId, HealthStatus, regionShouldRespectGracePeriodSets the health status of the specified instance. For more information, see Set up a custom health check for your Auto Scaling group in the Amazon EC2 Auto Scaling User Guide.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
HealthStatusstringThe health status of the instance. Set to Healthy to have the instance remain in service. Set to Unhealthy to have the instance be out of service. Amazon EC2 Auto Scaling terminates and replaces the unhealthy instance.
InstanceIdstringThe ID of the instance.
regionstringAWS region (default: us-east-1)
ShouldRespectGracePeriodbooleanIf the Auto Scaling group of the specified instance has a HealthCheckGracePeriod specified for the group, by default, this call respects the grace period. Set this to False, to have the call not respect the grace period associated with the group. For more information about the health check grace period, see Set the health check grace period for an Auto Scaling group in the Amazon EC2 Auto Scaling User Guide.

UPDATE examples

Sets the health status of the specified instance. For more information, see Set up a custom health check for your Auto Scaling group in the Amazon EC2 Auto Scaling User Guide.

UPDATE aws.autoscaling.instance_healths
SET
-- No updatable properties
WHERE
InstanceId = '{{ InstanceId }}' --required
AND HealthStatus = '{{ HealthStatus }}' --required
AND region = '{{ region }}' --required
AND ShouldRespectGracePeriod = {{ ShouldRespectGracePeriod}};