We have a single instance NAT server. We want to create an alarm that checks the metric StatusCheckFailed_Instance and reboots the instance.
this is described in the documents below.
I am able to define cloudwatch metric alarm
but I am having trouble defining an action alarm that reboots the instance/
Documentations says this about alarm_actions.
alarm_actions
- (Optional) The list of actions to execute when this alarm transitions into an ALARM state from any other state. Each action is specified as an Amazon Resource Number (ARN).
I also want to setup another alarm that checks for nat_system_check_failed and execute the action called "recover this instance"
Mostly like this is not possible in Terraform right now so I will use cloud formation but I wanted to be sure be I go that route.