How to Enable ContainerInsights on AWS ECS From the AWS CLI


If you need to enable Container Insights for an ECS cluster, by using the AWS CLI, then you can do the following:

aws ecs update-cluster-settings
    --cluster <cluster-name>  
    --settings name=containerInsights,value=enabled 
    --region <aws_region>