This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env ruby | |
| ################ DESCRIPTION ############################################################################### | |
| # PRECONDITIONS: must exists a lifeCicle to autoscaling called 'lifeCycle-actions-before-shut-down-instance' | |
| # POSTCONDITION: | |
| # Every 10 seconds check if instance lifeCycle status is Terminated | |
| # - if is terminated then | |
| # - do some actions. | |
| # - when all actions are done, then autoscaling lifeCycle is force completed to terminate intance manually | |
| ############################################################################################################ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| source 'https://rubygems.org' | |
| ruby '3.0.0' | |
| gem "bunny", ">= 2.19.0" | |
| gem "byebug" | |
| gem 'thread' |