Running apps on AWS · core
EC2 vs Lambda vs containers (ECS, Fargate)
EC2 gives you virtual machines you manage, ECS runs containers (on Fargate without managing servers), EKS is managed Kubernetes, and Lambda runs functions per request, so you trade control and steady-state cost against operations work and per-request scaling.
Explain it out loud
Explain it out loud to an AI interviewer that follows up, and see where your answer is thin.
Practise by voiceThe notes
What you must know
- EC2: VMs; you patch the OS; scale with Auto Scaling groups behind a load balancer; cheapest at steady load with reserved or savings plans; Graviton (arm64) instances are cheaper per performance.
- ECS + Fargate: run containers without managing servers; tasks behind an Application Load Balancer; scale on CPU or request count. ECS Express Mode (AWS's suggested replacement for App Runner) sets up a service, ALB and autoscaling in one step.
- AWS App Runner closed to new customers on 30 April 2026 (existing customers can keep using it, but it gets no new features).
- EKS: Kubernetes, for teams that need its ecosystem; more operational work.
- Lambda: per-request functions, scales automatically, max 15 minutes, cold starts, pay per use; great for events and spiky APIs.
- Typical Node web app: API on ECS Fargate or Lambda, static frontend on S3 + CloudFront, Postgres on RDS, Redis on ElastiCache, files on S3, queues on SQS.
The red pen
Common traps: mistake → fix
Mistake: Lambda is always cheapest
Fix: at steady high traffic, containers or EC2 often cost less.
Mistake: Fargate means no capacity planning at all
Fix: you still choose CPU/memory per task and scaling rules.
Easy to hard
Questions interviewers ask, easy to hard
- EC2 vs ECS/Fargate vs Lambda: when do you use each?
- How would you deploy an Express API on AWS?
- What is Fargate?
- How do you scale each option?
Explain it out loud
Explain it out loud to an AI interviewer that follows up, and see where your answer is thin.
Practise by voiceYour first interview is free
Sign up and start with a 15-minute interview with the full report, and an English conversation. No card needed.