How to get the version of currently running task definition using aws cli
AWS cli provides the option to get the the version of currently running task definition.
#aws ecs describe-services --cluster CLUSTER_NAME --services SERVICE_NAME | jq -r '.services[].taskDefinition' | cut -d / -f 2
Where CLUSTER_NAME and SERVICE_NAME need to be replaced with the corresponding values in ECS.
That's all…