Lesson 18 of 36 · see all lessons
  1. Start here: cloud concepts (domain 1, 24%)

    1. 1. Start here: the exam, the plan and what you already know
    2. 2. What the cloud is: benefits, service models and deployment models
    3. 3. AWS global infrastructure: Regions, Availability Zones and edge locations
    4. 4. Cloud economics: what you pay for on-premises vs in the cloud
    5. 5. The AWS Well-Architected Framework: six pillars
    6. 6. Moving to AWS: the Cloud Adoption Framework and migration strategies
  2. Security and identity (domain 2, 30%)

    1. 7. The shared responsibility model: who secures what
    2. 8. IAM basics: users, groups, roles and policies
    3. 9. Protecting the root user, MFA and credentials
    4. 10. Identity at scale: IAM Identity Center, federation and cross-account access
    5. 11. Encryption and keys: protecting data at rest and in transit
    6. 12. Threat protection: Shield, WAF, GuardDuty, Inspector and Security Hub
  3. Governance, ways of working and compute (domains 2 and 3)

    1. 13. Logging, auditing and compliance: CloudWatch, CloudTrail, Config and Artifact
    2. 14. Governing many accounts: Organizations, Control Tower and Service Catalog
    3. 15. Ways to use AWS: console, CLI, SDKs and infrastructure as code
    4. 16. Amazon EC2: virtual servers and instance types
    5. 17. Elasticity: Auto Scaling and Elastic Load Balancing
    6. 18. Containers and serverless: ECS, EKS, Fargate, Lambda and more
  4. Storage, databases and networking (domain 3, 34%)

    1. 19. Block and file storage: EBS, instance store, EFS and FSx
    2. 20. Amazon S3: buckets, storage classes and lifecycle policies
    3. 21. Hybrid storage, backup and disaster recovery
    4. 22. Databases: RDS, Aurora, DynamoDB, ElastiCache and more
    5. 23. Networking: VPCs, subnets, gateways and security layers
    6. 24. Connecting and delivering: Route 53, CloudFront, VPN and Direct Connect
  5. Analytics, AI, integration and more (domain 3)

    1. 25. Analytics services: Athena, Glue, Kinesis, Redshift and Quick
    2. 26. AI and machine learning services: SageMaker AI, Lex, Rekognition and Amazon Q
    3. 27. App integration and business apps: SQS, SNS, EventBridge, Connect and SES
    4. 28. Developer tools, end-user computing, Amplify and IoT
  6. Billing, pricing and support, then exam practice (domain 4, 12%)

    1. 29. Pricing models: On-Demand, Savings Plans, Reserved, Spot and Dedicated
    2. 30. Billing and cost tools: Budgets, Cost Explorer, Pricing Calculator and tags
    3. 31. AWS Support plans, Trusted Advisor and where to get help
    4. 32. Final review and exam day: every decision on one page
    5. 33. Mock exam 1
    6. 34. Mock exam 2 Exam Pack · $12
  7. Extra practice: mock exams 3 and 4

    1. 35. Mock exam 3 Exam Pack · $12
    2. 36. Mock exam 4 Exam Pack · $12
See the leaderboard

19 min

Containers and serverless: ECS, EKS, Fargate, Lambda and more

Choose between containers, serverless functions and other compute options like Batch, Beanstalk and Outposts.

By the end of this lesson you can

  • Explain containers and tell Amazon ECS from Amazon EKS
  • Describe what AWS Fargate and AWS Lambda take off your hands
  • Recognize when AWS Batch, AWS Elastic Beanstalk, AWS Outposts or Amazon Lightsail fits
  • Choose a compute service from a scenario's deciding word

From earlier lessons · 1 of 2

Which service adds and removes EC2 instances as demand changes?

Pick one answer.

From earlier lessons · 2 of 2

A website must send /search and /cart requests to different server groups behind one address. Which load balancer fits?

Pick one answer.

Cedar Lane Books' developers packed the stock system into containers, and it runs the same on every laptop. Now they ask: where do the containers run in AWS, and who looks after those servers? Marketing has a smaller wish. Every time staff upload a book cover, they want a thumbnail made, with no server sitting idle in between.

[4]

Containers and Amazon ECR

Exam depth: know it cold.

A container packages an application with everything it needs: code, libraries and settings. It runs the same way on a laptop, a test server or AWS. Containers share their host's operating system, so they use fewer resources than full virtual machines.

You build a container from an image, a saved template of the package. Images live in a registry.

Amazon Elastic Container Registry (Amazon ECR) is AWS's managed registry. You push images to it and pull them from it, privately or publicly. ECR can also scan images for known software vulnerabilities.

[194][196]

Amazon ECS or Amazon EKS

Exam depth: know it cold.

An orchestrator starts, stops, places and scales your containers. AWS offers two.

Amazon ECSAmazon EKS
What it isAWS's own fully managed container orchestrator.A fully managed Kubernetes service.
KubernetesNot used.Kubernetes is open-source orchestration software used across clouds.
EffortSimpler, lower operational overhead.More to learn, larger ecosystem.
PortabilityBuilt for AWS.Standard Kubernetes APIs move across clouds and on premises.

Decision rule: the word "Kubernetes", an existing Kubernetes team, or a need to move between clouds picks EKS. Otherwise, the simpler AWS-native choice is ECS.

[194][197][198]

Where containers run: EC2 or AWS Fargate

Exam depth: know it cold.

After the orchestrator, you choose where the containers actually run.

  • Amazon EC2 instances: you run a cluster of instances. You pick instance types, patch them, scale them and pack containers onto them. Most control, most work.
  • AWS Fargate: serverless compute for containers. You say how much CPU and memory each container needs, and AWS runs it. No instances to choose, patch or scale.

Fargate works with Amazon ECS and Amazon EKS, and AWS Batch can use it too.

Decision rule: "containers" plus "no servers to manage" or "least operational overhead" picks Fargate. "Specific instance types" or "full control of the hosts" picks EC2.

[194][199]

Rendering diagram…
Images come from ECR. Pick an orchestrator first, then pick EC2 or Fargate to run the containers.

[194]

Cedar Lane Books wants to run its containerized stock system on Amazon ECS. The small IT team doesn't want to provision, patch or scale any servers. Which option meets this requirement?

Pick one answer.

[199]

A company already runs its applications on Kubernetes in its own data center. It wants a managed service on AWS that keeps the same Kubernetes tools. Which AWS service should it choose?

Pick one answer.

[194][198]

Serverless and AWS Lambda

Exam depth: know it cold.

Serverless means servers still exist, but you never see or manage them. AWS handles capacity, patching and scaling. It scales automatically, even down to zero. You pay for use, not for idle capacity.

AWS Lambda runs your code in response to events. An event might be a file landing in Amazon S3, a message in a queue or an API call.

  • You upload a function. Lambda runs it only when an event arrives.
  • It scales automatically, one copy per request if needed.
  • You pay per request plus compute time used. Idle time costs nothing.
  • One run, called an invocation, can last up to 30 minutes.

AWS raised that limit from 15 minutes. Older study guides still say 15.

[65][200][201]

Watch it happen · 10 s

A book cover upload triggers Lambda

No uploads, so no function runs and nothing is billed.

Scene 1 of 4

[65]

[201]

Each time a customer uploads a photo to Amazon S3, a company must resize it. Uploads are rare and unpredictable. The company wants to pay nothing when no photos arrive. Which service fits best?

Pick one answer.

[65]

Serverless: the servers are still there. They're just not your problem anymore. Picture: Three-panel comic strip style, clean ink lines and flat colors.

More compute options: Batch, Beanstalk, Outposts and Lightsail

Exam depth: recognize it.

ServiceWhat it doesThe scenario says
AWS BatchRuns batch jobs at any scale. It queues jobs and provisions the compute for them, on EC2 or Fargate."Thousands of batch jobs", "queue", "compute-intensive", "HPC".
AWS Elastic BeanstalkYou upload web app code. Beanstalk provisions servers, load balancing, scaling and health monitoring. The resources stay in your account, and Beanstalk itself is free."Just upload the code", "developers, not infrastructure".
AWS OutpostsAWS-managed racks or servers in your own building, using the same AWS services and APIs."On premises", "low latency to local systems", "data must stay on site".
Amazon LightsailSimple virtual private servers and bundles for a predictable monthly price."Simple website", "fixed monthly price", "little cloud experience".

[20][32][180][195][202][203]

A developer has written a Java web application. She wants to upload the code and have AWS handle the servers, load balancing and scaling, without writing infrastructure templates. Which service fits best?

Pick one answer.

[20]

A factory needs very low latency between its apps and the machines on its own site. It wants to use the same AWS services and APIs it uses in the cloud. Which AWS service meets these requirements?

Pick one answer.

[32][195]

Choosing compute: the whole picture

Exam depth: know it cold.

Read the table from most control to least work.

ServiceYou managePick it when
Amazon EC2The OS, patches, scaling setup.You need full control of a virtual server.
ECS or EKS on EC2The container hosts.Containers that need specific instance types.
ECS or EKS on FargateOnly your containers.Containers with no servers to manage.
AWS LambdaOnly your code.Short tasks triggered by events.
AWS BatchYour jobs.Large numbers of batch jobs.
AWS Elastic BeanstalkYour app code.A web app with the setup handled for you.
Amazon LightsailA simple server.A small site at a fixed monthly price.
AWS OutpostsYour site's space and power.AWS services on your own premises.

Decision rule: find the deciding word first, such as "Kubernetes", "event", "batch", "upload the code", "monthly price" or "on premises". Then match it to the row.

[194][195]

Match

Match each Cedar Lane Books need to the compute service that fits it.

Pick an item on the left, then its match on the right.

[195]

[194]

Exam-style practice

A research lab submits thousands of compute-heavy simulation jobs each week. It wants AWS to queue the jobs and provision the right compute for them, without installing batch software. Which service fits?

Pick one answer.

[202]

A company runs its containers on Amazon EKS. It wants to stop managing the EC2 instances under the containers. Which option has the LEAST operational overhead?

Pick one answer.

[198][199]

A development team needs a private, managed place on AWS to store its Docker container images, and to scan them for known vulnerabilities. Which service should it use?

Pick one answer.

[196]

FlashcardsIndex cardsFlashcards ⚡

Card 1 of 17

[20][32][65][194][199][201][202]

Worth keeping

  1. ECR stores container images; ECS and EKS run them; EKS is the Kubernetes choice.
  2. Fargate runs containers with no servers to manage, for ECS and EKS.
  3. Lambda runs short code on events, scales itself and bills per request and run time.
  4. Batch is for job queues, Beanstalk for upload-the-code web apps, Outposts for AWS on premises, Lightsail for simple sites.
  5. Find the deciding word, then match the service.

On the job

A prospect tells a salesperson that the team already runs Kubernetes. They're also tired of patching servers. Two answers fit in one sentence: Amazon EKS keeps their Kubernetes tools, and Fargate removes the servers. A finance manager asks why the thumbnail feature costs pennies. Lambda bills only when a cover is uploaded, so quiet nights cost nothing.

Every one of these services needs somewhere to keep its data, and an instance store wipes itself on a stop. Next lesson: block and file storage with EBS, EFS and FSx.

Leaderboard

Loading…

50 XP for each lesson you finish, 10 for each right answer. Names show only for learners who turn on Show me on leaderboards.

Embed this practice on your site

Free for classrooms, blogs and study groups. Paste this into any page that accepts HTML.

Report a copyright problem with this lesson

Sources for this lesson (15)

Each fact in the lesson is marked with the number of the page it comes from.

  1. [4]AWS: CLF-C02 Content Domain 3: Cloud Technology and Services
  2. [20]AWS: What is AWS Elastic Beanstalk?
  3. [32]AWS: What is AWS Outposts?
  4. [65]AWS: What is AWS Lambda?
  5. [180]AWS: What is Amazon Lightsail?
  6. [194]AWS: Choosing an AWS container service
  7. [195]AWS: Choosing an AWS compute service
  8. [196]AWS: What is Amazon Elastic Container Registry?
  9. [197]AWS: What is Amazon Elastic Container Service?
  10. [198]AWS: What is Amazon EKS?
  11. [199]AWS: Architect for AWS Fargate for Amazon ECS
  12. [200]AWS: Serverless on AWS
  13. [201]AWS: Lambda quotas
  14. [202]AWS: What is AWS Batch?
  15. [203]AWS: AWS Elastic Beanstalk