Open cristim opened 1 year ago
Voting for Prioritization
Volunteering to Work on This Issue
Hey @cristim 👋 Thank you for taking the time to raise this! I took a look over this, and I believe that everything is already in place for this as it stands today, though the structure looks a little different than your sample configuration. The equivalent Terraform configuration would be something like:
resource "aws_ecs_service" "example" {
# ...other configuration...
deployment_maximum_percent = 200
deployment_minimum_healthy_percent = 50
deployment_circuit_breaker {
enable = true
rollback = true
}
alarms {
alarm_names = ["HighResponseLatencyAlarm"]
enable = true
rollback = true
}
}
Hey @cristim 👋 Thank you for taking the time to raise this! I took a look over this, and I believe that everything is already in place for this as it stands today, though the structure looks a little different than your sample configuration. The equivalent Terraform configuration would be something like:
resource "aws_ecs_service" "example" { # ...other configuration... deployment_maximum_percent = 200 deployment_minimum_healthy_percent = 50 deployment_circuit_breaker { enable = true rollback = true } alarms { alarm_names = ["HighResponseLatencyAlarm"] enable = true rollback = true } }
Hi @justinretzolk,
On the other hand, when 'alarms' is removed, this is not reflected in the resource previously created with 'alarms'.
Ex.
alarms {
alarm_names = []
enable = false
rollback = false
}
Did you observe this?
Description
This is a relatively new feature documented in this blog post, which allows ECS to automatically rollback deployments in case of failures:
Here's how the new parameter looks like in JSON, as per the above blog:
And here's how to do the same in CloudFormation.
Affected Resource(s) and/or Data Source(s)
aws_ecs_service
Potential Terraform Configuration
References
Would you like to implement a fix?
No