Play Video

Summary

Walkthrough of creating AWS CloudFormation stacks to deploy and run docker containers on Amazon Elastic Container Service (ECS) with AWS Fargate. This involves creating Elastic Container Registry (ECR), multiple CloudFormation stacks for groups of resources on cloud – VPC, Subnets, Load balancers, CloudWatch, ECS Cluster, Container Tasks and Services etc.

Following are the steps to walk through,
  1. Containerize a simple REST API application – Build Docker Image
  2. Using AWS CLI, create a repository on Amazon Elastic Container Registry (Docker Registry)
  3. Push the docker image to the repository on Amazon ECR
  4. Define and run CloudFormation stack to create VPC and all network components
  5. Define and run CloudFormation stack to create IAM roles
  6. Define and run CloudFormation stack to create ECS Cluster, Load balancer, CloudWatch Log Group, and Security Groups
  7. Define and run CloudFormation stack to deploy docker application – Create Task for container, Service to schedule the task, Load balancer target group for container services, and Load balancer listener rule for container service

Resources