Hello!
Many were faced with the fact that system resources are idle. The usual practice in dealing with downtime is to remove these resources from the system. From a practical point of view on AWS, we have already had tools for terminating idle EC2 instances for a long time. But this is sometimes not practical.
Let's take a situation when each time you start a new instance with autoscaling, it is configured each time and updates the software. Those. it takes some time and requires certain interactions. And every time when scaled down, these instances are turned off and deleted, and when scaled out, they are raised and reconfigured. It would be nice if the instances were just turned off and not deleted!
Starting today, we have the ability to set instances behavior in alarms based on CloudWatch metrics. We are available:
- Stop - Stop
- Uninstall - Terminate
')
When creating an alarm through the CLI, you can also specify what to do:
-- alarm-actions arn:aws:automate:us-east-1:ec2:stop -- alarm-actions arn:aws:automate:us-east-1:ec2:terminate
As always, AWS adds even more flexibility to high availability applications.