ECS - Elastic Container Service Flashcards
What is ECS?
Amazon Elastic Container Service (Amazon ECS) is a fully managed container orchestration service
What is popular for ECS and Docker?
microservices and migration
Where are apps packaged in Docker?
in containers
What OSs, languages and technologies can be run into Docker containers?
any OS, language, or technology
How interact and how are impacted the Docker containers that are running on the same machine
they don’t interact with each other unless we tell them to and they don’t impact each other, so if one application is going crazy the other ones won’t be impacted
Where are Docker images stored?
Docker images are stored in Docker Repositories and there are two types of repositories:
o Public: Docker Hub https://hub.docker.com/
Find base images for many technologies or OS:
- Ubuntu
- MySQL
- NodeJS
- Java…
o Private: Amazon ECR (Elastic Container Registry)
What is the main difference between Docker and a VM?
Docker containers run on the Docker Engine which uses just 1 Guest OS.
Each app in a VM run on a Guest OS and these OS run on the Hypervisor
Whar are the ECS flavors?
- ECS “Classic”
- Fargate: ECS
- EKS
What is ECS “Classic”?
Provision EC2 instances to run containers onto.
What you must configure in EC2 to use ECS “Classic”?
We must configure the file /etc/ecs/ecs.config with the cluster name.
What is Fargate?
ECS Serverless, no more EC2 to provision
What is EKS?
Managed Kubernetes by AWS
What are ECS clusters?
logical grouping of EC2 instances running the ECS agent
What is the job of the ECS agent?
to register the instance to the ECS cluster
What can you say about the EC2 instances AMI used in an ECS cluster?
The EC2 instances run a special AMI, made specifically for ECS
Can you create an empty ECS cluster?
Yes, by just defining its name
In ECS “Classic” what kind of Instance Launch types can be used?
On-demand and spot instances
What Instance configuration can you define in an ECS “classic” definition?
o EC2 instance launch type o EC2 instance type o # of instances. o EC2 AMI id. o EBS storage (GB). o Key pair.
How is CloudWatch integrated to ECS?
CloudWatch Container Insights: Each container will have a different log stream.
How is used the EC2 instances CPU and memory in ECS?
The EC2 instances in the cluster each have CPU and Memory values that are going to be shared among the containers.
What is created by default when you finish defining the ECS instance configuration?
By default, an Auto Scaling Group is created in the cluster based on your instance configuration provided in the cluster
When an instance in ECS starts how does it know to register to the cluster?
It uses the Instance User Data
What are ECS tasks definitions?
Tasks definitions are metadata in JSON form to tell ECS how to run a Docker Container
What are the 4 most important aspects defined in an ECS task definition?
o Docker Image
o Port Binding for Container and Host (no needed for Fargate)
o Memory and CPU required
o IAM Task Role