An ECS container instance is an EC2 instance that’s:
- running Amazon’s ECS container agent and
- has been registered into a cluster
- the container agent is automatically installed if you’re using an Amazon ECS-optimized AMI
- the agent will make API calls to Amazon ECS so the instances will need an IAM role
For more on this see:
Note, however, if you’re using Fargate this does not apply (see docs).
AWS Fargate is a compute engine for Amazon ECS and EKS that allows you to run containers without having to manage servers or clusters. With AWS Fargate, you no longer have to provision, configure, and scale clusters of virtual machines to run containers.
Fargate is not currently (August 2018) available in the UK.
How does this differ from ECS (Elastic Container Service) and EKS (Elastic Container Service for Kubernetes) though?
Amazon Elastic Container Service (Amazon ECS) is a highly scalable, high-performance container orchestration service that supports Docker containers and allows you to easily run and scale containerized applications on AWS. Amazon ECS eliminates the need for you to install and operate your own container orchestration software, manage and scale a cluster of virtual machines, or schedule containers on those virtual machines.
ECS was first to market as a commercial container service between the big players and is now suffering as it’s rather out-dated. It’s basically Docker as a Service offering a Docker Registry (aka Amazon Elastic Container Registry or ECR) and support in its CLI for Docker Compose.
EKS (aka Amazon Elastic Container Service for Kubernetes) is a managed Kubernetes service.
The differences? Use:
- ECS if you like using Docker
- EKS if you like Kubernetes
- Fargate if you don’t want to managing either Docker or Kubernetes
See also https://dzone.com/articles/ecs-vs-eks-vs-fargate-the-good-the-bad-the-ugly