Reputation: 59
I am currently using ECS to deploy a web application. This Application is pushed on my ECR with the latest
tag but putting new images doesn't seem to change the code at deployment.
I tried to use the answer found here How do I deploy updated Docker images to Amazon ECS tasks? using aws ecs update-service --cluster <cluster name> --service <service name> --force-new-deployment
.
I also put ECS_IMAGE_PULL_BEHAVIOR=always
in my ecs config and deployment_minimum_healthy_percent = 0
and deployment_maximum_percent = 200
in my deployment settings.
I notice that the image digest is matching the latest
image, but by logging on the container, the code is not different from the previous version. But by executing docker pull <my_image:latest>
the changes are there.
Upvotes: 2
Views: 3059
Reputation: 11
You need to update task definition first (create new one) and then deploy it.
ECS task definition
CLI for register task
Upvotes: 1