How can I leave prev task definition as activate status. #5300
-
|
Hi. I'm using AWS Copilot Backend Service. So, I want to ask two things.
Thanks for read my discussion :) |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
|
Yup! You can use yaml patch to update the - op: add
path: /Resources/TaskDefinition/UpdateReplacePolicy
value: RetainEdit: I will add a bit explanation on why this would work. The task definition became INACTIVE because when CFN updates the stack, it under the hood By adding |
Beta Was this translation helpful? Give feedback.
Yup! You can use yaml patch to update the
TaskDefinition'sUpdateReplacePolicytoRetain:Edit: I will add a bit explanation on why this would work.
The task definition became INACTIVE because when CFN updates the stack, it under the hood
CREATEa task definition with a new revision, andDELETEthe old task definition revision. In this case, "delete" means "deregistering" the old task def, resulting in the old task def revision becoming INACTIVE.By adding
UpdateReplacePolicy: Retain, we prevent CFN to do the "delete" step, hence keeping the old task def as ACTIVE.