I want to implement a two-phase deployment strategy using CircleCI. Here’s my goal:
- On every commit: build Docker images for multiple services from a monolithic codebase, tag them, and push to ECR.
- Later, manually choose a specific image tag to deploy to either Dev or Prod environments — enabling controlled promotions and rollbacks.
For deployments:
- I use ECS Fargate, where the task definition points to
:latest. - To deploy, I apply the
latesttag to the chosen image in ECR, triggering an ECS service update. - For rollbacks, I simply move the
latesttag back to a previous image.
I also use separate ECR repos for Dev and Prod. Once an image is tested in Dev, I copy it from the Dev ECR to Prod ECR and apply the latest tag — avoiding redundant builds.
I’ve implemented this successfully with GitHub Actions, but the UI makes it hard for developers to navigate due to the scale (15+ services). CircleCI’s deployment workflows and approval gates look promising.
Can CircleCI support this workflow effectively? Specifically:
- Build once, deploy multiple times
- Manual promotion between environments
- Easy rollback via image tagging
- Clear visibility for developers