ECS, ECR & Fargate - Docker in AWS Flashcards
What is Docker?
A software development platform to deploy apps
How does Docker work?
Packages apps in containers that can be run on any OS
Two types of Docker Repositories?
- Docker Hub (public repo)
- Amazon ECR (amazon docker repo)
Where are Docker images stored?
Docker Repositories
What is Amazon ECR?
Amazon Elastic Container Registry
Amazon’s own container platform?
Amazon Elastic Container Service (Amazon ECS)
Amazon’s managed Kubernetes (open source)?
Amazon Elastic Kubernetes Service (Amazon EKS)
What is Amazon’s own Serverless container platform and works with ECS and with EKS?
AWS Fargate
Amazon service that stores container images
Amazon ECR
How do you launch Docker containers using EC2 Launch Type in Amazon ECS?
Launch ECS tasks on an ECS cluster with EC2 instances.
Each EC2 Instance ….. the ….. to register in the ECS Cluster
must run, ECS Agent
When must you provision & maintain the infrastructure (the EC2 instances)
When running ECS with a EC2 Launch type.
When running EC2 launch type on ECS what will AWS take care of?
starting / stopping container
What is a launch type?
A configuration that determines how your Docker containers are deployed and ran.
What does Amazon Elastic Container Service do?
Orchestrates container deployment, and launch types specify the underlying infrastructure used by ECS to run those containers.
How do you launch Docker containers using Fargate Launch Type in Amazon ECS?
It’s serverless, no need to provision infrastructure.
You just create task definitions
When running Fargate launch type on ECS what will AWS take care of?
AWS just runs ECS Tasks for you based on the CPU / RAM you need
How can you scale your Fargate launch Type containers?
Just increase the number of tasks.
Features:
- Used by the ECS agent
- Makes API calls to ECS service
- Send container logs to CloudWatch Logs
- Pull Docker image from ECR
- Reference sensitive data in Secrets Manager or SSM Parameter Store
EC2 Instance Profile (EC2 Launch Type only)
Features:
- Allows each task to have a specific role
- Use different roles for the different ECS Services you run
- Task Role is defined in the task definition
ECSTask Role
Which ELB is supported and works for most use cases in Amazon ECS
Application Load Balancer
Which ELB is recommended only for high throughput / high performance use cases, or to pair it with AWS Private Link in Amazon ECS
Network Load Balancer
Can you mount EFS file systems onto ECS tasks?
Yes
Can Amazon S3 be mounted as a file system?
No