riker icon indicating copy to clipboard operation
riker copied to clipboard

Use instances and images more efficiently

Open jschementi opened this issue 10 years ago • 0 comments

Currently running riker deploy --scale from scratch does the following:

  1. Creates a new instances
  2. Provisions it with docker, nginx, and any other dependencies
  3. Creates AMI (A)
  4. Terminates instance
  5. Launches instance from AMI (A)
  6. Deploys app to instance
  7. Creates AMI (B)
  8. Terminates instance
  9. Launches instance from AMI (B) (only if --scale isn't provided), or adds AMI (B) to an auto-scaling group to launch instance.

Can be compressed by not terminating the instance in #4, therefore skipping #5. If --scale is not provided, #8 and #9 can be skipped too. If --scale is provided, then that instance can be added directly to the auto-scaling group.

This will greatly improve deployment time, as AMI creation and instance termination take quite a bit of time.

jschementi avatar Dec 31 '14 06:12 jschementi