amazon-ecs-deploy-task-definition
amazon-ecs-deploy-task-definition copied to clipboard
Can I use an existing task-definition instead of creating new?
Use case - Task definitions are managed by Terraform, we do not want the taskdef version to be updated from Github actions.
It's like a force deployment of latest version of an existing task definition in ECS service.
Ref - https://github.com/aws-actions/amazon-ecs-deploy-task-definition/issues/70
Hi @vivekyad4v, I think this might help?
- name: Download current task definition
run: |
aws ecs describe-task-definition --task-definition ${{ env.ECS_TASK_DEFINITION }} --query taskDefinition > task-definition.json
Any update on this? We have the same issue, where cdk creates a task definition. We download it using the method described above, but ultimately results in two task definitions. One from cdk deploy, and one from the ecs deploy
Any update on this? We have the same issue, where cdk creates a task definition. We download it using the method described above, but ultimately results in two task definitions. One from cdk deploy, and one from the ecs deploy
Similar issue, but looks like no one has chimed in yet with a solution
Using the existing one instead of creating new is really important 'cause the number of revisions per task definition has a limit: https://docs.aws.amazon.com/AmazonECS/latest/developerguide/service-quotas.html
Maybe the problem is in this place:

It seems that always is registering a new task-definition.
I don't have time right now to fix this, but I can help in a few months '-'
What about making the task definition optional? The service update from ECS supports this and uses the active definition for the given service
Any update on this? We have the same issue.