ECS Auto Scaling
In Harness, you configure ECS Service Auto Scaling in the ECS Service Setup step of a Workflow.
- In a Workflow with the ECS Service Setup step, open the ECS Service Setup step.
- In Auto Scaler Configurations, the Auto Scaling property fields appear.
When Harness deploys your ECS service, it will register the service with ECS Service Auto Scaling to apply the scaling policy, scaling out (and in) using CloudWatch target tracking.
Auto Scaling is added after the Last Upgrade Containers Step
By default, when you create an ECS Workflow of any supported type (Basic, Blue/Green, Canary), Harness automatically adds ECS Auto Scaling after the last Upgrade Containers step in the last Phase in a Workflow.
For example, in an ECS Canary Workflow, ECS Auto Scaling is added after the Upgrade Containers step in Phase 2.
Upgrade Containers and Rollback Containers Steps are Dependent
In order for rollback to add ECS Auto Scaling to the previous, successful service, you must have both the Upgrade Containers and Rollback Containers steps in the same Phase.
Since ECS Auto Scaling is added by the Upgrade Containers step, if you delete Upgrade Containers, then Rollback Containers has no ECS Auto Scaling to roll back to.
Deleting Upgrade Containers Step
If you delete the Upgrade Containers step from Phase 2, ECS Auto Scaling is not added because Phase 2 is missing the Upgrade Containers step.
To ensure that ECS Auto Scaling is applied, you can add the Upgrade Containers step in Deploy Containers to Phase 1.
Rollback when Auto Scaling is Enabled
See ECS Rollbacks.