This is a terraform example that launches Tomcat base container image on to an ASG-backed ECS cluster. The bootstrap script installs the SSM agent and mounts the EFS file system to be used for future ambitions. Note that it takes several minutes after Terraform completes for the ECS tasks to run, register with the ALB and become healthy.
Create SSH keys in the keys directory
ssh-keygen -t rsa -f ./keys/mykey -N ""