AWS090 - ECS clusters should have container insights enabled

Explanation

Cloudwatch Container Insights provide more metrics and logs for container based applications and micro services.

Insecure Example

The following example will fail the AWS090 check.

resource "aws_ecs_cluster" "bad_example" {
  	name = "services-cluster"
}

Secure Example

The following example will pass the AWS090 check.

resource "aws_ecs_cluster" "good_example" {
	name = "services-cluster"
  
	setting {
	  name  = "containerInsights"
	  value = "enabled"
	}
}