0

We have a multi-step deployment procedure:

  • Step 1 -> Send assets to S3, other prep work, and trigger elastic beanstalk deployment (occurs on CircleCI)
  • Step 2 -> Elastic Beanstalk deployment (occurs on AWS)

What I'd like to do is block Circle builds until Step 2 has completed (Elastic Beanstalk deployment is in 'ready' state) to prevent additional builds from failing. One strategy to accomplish this is to include a 'wait' script as the last step in the build of Step 1 that would wait for the EB environment to return "ready". However, this will cost us unnecessary Circle credits so I'd rather not do it this way. Maybe there's a way to tell Circle to retry builds if EB is not in a 'ready' state?

What are some other strategies to accomplish this?

nratter
  • 397
  • 4
  • 14

1 Answers1

0

The way that I solved this was by putting an 'infinite' loop at the beginning of my deploy script that checked the EB environment status. If the status is "Ready", it broke out of the loop and continued executing the deployment script.

nratter
  • 397
  • 4
  • 14