Container services: choosing the right one
What each of the six SAA-C03 container services does, how to choose between ECS and EKS, Fargate and EC2, and the cloud, on-premises, and self-managed options, and how to go from the clues in a question to the right service.
4 min read · Last reviewed · SAA-C03
Sign in to bookmark tutorials and track what you have read.
On this page
The services at a glance
The Containers category of the exam covers six services. One stores container images; the others orchestrate containers, which means deciding where each container runs, keeping the right number running, and replacing failed ones. Each service name links to its own tutorial.
| Service | What it does |
|---|---|
| Amazon ECR | A managed registry that stores, scans, and replicates container images |
| Amazon ECS | AWS's own container orchestrator: simple, deeply integrated with AWS, no control plane to manage |
| Amazon EKS | Managed Kubernetes: AWS runs the Kubernetes control plane, and you use standard Kubernetes tools |
| Amazon ECS Anywhere | Runs ECS tasks on your own servers or VM (Virtual machine)A software computer that runs its own operating system on shared physical hardware, kept apart from other VMs by a hypervisor. An EC2 instance is a VM, except bare metal instances.Glossary entry, managed from the ECS control plane in AWS |
| Amazon EKS Anywhere | Runs Kubernetes clusters on your own infrastructure, built on EKS Distro, even with no connection to AWS |
| Amazon EKS Distro | The Kubernetes distribution that EKS uses, for you to run and support yourself anywhere |
AWS Fargate, the serverless compute for ECS and EKS, belongs to the exam's Serverless category, but it appears in almost every container question.
Three choices to make
- Orchestrator: ECS or EKS? Choose ECS for the simplest way to run containers on AWS. Choose EKS when the team already uses Kubernetes, needs Kubernetes tools and API (Application programming interface)A defined way for one program to ask another for data or actions, such as a set of HTTPS requests and responses. Every AWS service is controlled through its API, which the console, the CLI, and the SDKs call for you.Glossary entry, or wants to run the same workloads on other clouds or On-premisesIn data centers or offices that you run yourself, rather than in the cloud. Hybrid architectures connect on-premises systems to AWS, for example through AWS Direct Connect or a VPN.Glossary entry.
- Compute: Fargate or EC2? Choose Fargate to run containers with no servers to manage, paying per task. Choose EC2 when you need specific instance types such as GPU (Graphics processing unit)A processor with thousands of small cores that run many calculations in parallel. GPUs speed up machine learning, graphics, and video work; EC2 instance families such as P and G include them.Glossary entry, control over the hosts, or the lowest cost at a large steady scale. Fargate Spot and EC2 Spot cut costs for work that can be interrupted.
- Location: AWS or your own data center? In an AWS RegionA separate geographic area where AWS runs its services, such as us-east-1 in Northern Virginia, made up of several Availability Zones. Most resources live in one Region; you choose Regions for latency, data residency, and the services you need.Glossary entry, use ECS or EKS. On premises, use ECS Anywhere or EKS Anywhere, or EKS Hybrid Nodes to add on-premises nodes to an EKS cluster in AWS. For AWS-managed hardware on premises, run Amazon EKS on AWS Outposts; a local cluster keeps its AWS-managed control plane on the Outpost and keeps running if the link to AWS is cut. To run Kubernetes entirely yourself with the same distribution as EKS, use EKS Distro.
Every option stores its images in ECR.
Reverse mindmap: from the question to the service
- Store the images
- Private registry for container images leads to Amazon ECR
- Scan images for vulnerabilities leads to ECR image scanning
- Images in another Region or account leads to ECR replication
- Run containers in AWS
- Simplest orchestration, AWS-native leads to Amazon ECS
- Existing Kubernetes skills and tools leads to Amazon EKS
- No servers or clusters to manage leads to Fargate with ECS or EKS
- GPUs or control over the hosts leads to EC2 capacity
- Lowest cost, interruptible tasks leads to Fargate Spot or EC2 Spot
- Run containers outside AWS
- ECS tasks on our own servers leads to ECS Anywhere
- Kubernetes on premises, even disconnected leads to EKS Anywhere
- AWS-managed hardware and control plane on premises, through disconnects leads to EKS local cluster on Outposts
- Self-supported Kubernetes, same build as EKS leads to EKS Distro
Commonly confused pairs
| If the choice is between | Choose the first when | Choose the second when |
|---|---|---|
| ECS or EKS | You want the simplest AWS-native orchestration | You need Kubernetes compatibility and tools |
| Fargate or EC2 capacity | You want no servers to manage | You need specific instances, GPUs, or host control |
| ECS Anywhere or EKS Anywhere | You run ECS and want AWS to manage the control plane | You need Kubernetes on premises, possibly without an AWS connection |
| EKS Anywhere or EKS Distro | You want a supported on-premises Kubernetes product | You want only the Kubernetes distribution, and support it yourself |
| Containers or Lambda | Long-running services, any runtime, full control of the image | Event-driven architectureA design in which services react to events that other services emit, such as an order placed or a file uploaded, instead of calling each other directly. Amazon EventBridge, Amazon SNS, Amazon SQS, and AWS Lambda are common building blocks.Glossary entry functions that run for up to 15 minutes |
Key takeaways
- ECR stores images; ECS and EKS run them; Fargate removes the servers.
- "Kubernetes" in a question points to EKS (or EKS Anywhere and EKS Distro outside AWS); otherwise ECS is usually the simpler answer.
- "No servers to manage" points to Fargate; "GPU" or "host control" points to EC2 capacity.
- On-premises containers point to ECS Anywhere or EKS Anywhere.
Sources
- AWS Certification: SAA-C03 in-scope AWS services
- Amazon ECR User Guide: What is Amazon Elastic Container Registry?
- Amazon ECS Developer Guide: What is Amazon Elastic Container Service?
- Amazon EKS User Guide: What is Amazon EKS?
- Amazon ECS Developer Guide: Amazon ECS clusters for external instances (ECS Anywhere)
- Amazon EKS User Guide: Deploy Amazon EKS on-premises with AWS Outposts
- Amazon EKS Anywhere documentation: Overview
- Amazon EKS Distro