Skip to content
This repository has been archived by the owner on Jan 6, 2022. It is now read-only.
/ aws-ha-updater Public archive

update an aws stack and its asgs in a high-available manner

License

Notifications You must be signed in to change notification settings

Scout24/aws-ha-updater

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

92 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

aws-ha-updater

This project is DEPRECATED and not any longer supported

The aws-ha-updater allows you to update AWS Cloudformation stacks in a highly available manner.

Why another tool?

  • Raw CloudFormation would be the preferred solution for rolling out updates, but CloudFormation is currently unable to use the ELB health check to see if an instance with a new launch configuration comes up healthy. The result is that deployment with CloudFormation is a gamble that might result in a cluster of borked instances, which is not acceptable for a web company.

  • Asgard, the netflix solution to this, is being rewritten and nobody knows for sure when 2.0 will hit the repository.

  • The aws-missing-tools repository provides a bash and ruby implementation. We're not comfortable with using bash to instrument EC2/CFN, and have not evaluated the ruby variant. This solution is however heavily inspired by the aws-ha-release script from the missing-tools collection.

Prerequisites:

Usage

update-stack STACK_NAME [options] [PARAMETER...]

Options:
    --region=STRING            aws region to connect to [default: eu-west-1]
    --template=FILENAME or URL

    --warmup-seconds=INT       Seconds to wait for warmup [default: 25]
    --action-timeout=INT       Seconds to wait for the action to finish [default: 300]
    --lenient_look_back=INT    Seconds to look back for events [default: 5]

    PARAMETER...               key=value pairs, must correspond to the template parameters
update-asgs STACK_NAME [options]

Options:
    --region=TEXT   aws region [default: eu-west-1]

Big picture

update-stack

  • validate template file when given

  • create stack when needed

  • update stack and wait for action to complete

  • when successful: update asgs

update-asgs

  • suspend all autoscaling processes

  • double ASG sizes

  • wait for ASG to launch new instances

  • wait for instances to be "InService" according to ELB

    • when successful: terminate the old instances

    • when timeout occured: terminate the new instances

  • reset ASG sizes

  • resume all processes (when timeout: disable autoscaling processes)

About

update an aws stack and its asgs in a high-available manner

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published