I am having elastic beanstalk environment currently in Sydney and London region. I want to customize them so that I can set the Maximum instance lifetime for the auto scaling group. This will recreate the server if crossed particular lifetime.
I can set this parameter manually in ASG. However, whenever there is elastic beanstalk managed update running by AWS, it creates new ASG and this setting is removed.
I wanted to make this setting permanent via .ebextentions. However, I am unable to check any document which can say this particular parameter setting is possible via .ebextentions or hooks. I know I could use option_setting to customize EB infra. But what is the parameter name and how to set this here?
Beanstalk creates a CFN template, which is what the EBExtension is customizing. So you can set most parameters available in CFN in an EBExtension: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-autoscaling-autoscalinggroup.html#cfn-autoscaling-autoscalinggroup-maxinstancelifetime