End-to-end working tutorials for LocalEmu, the
open-source AWS emulator. Each folder is a self-contained project with
real Terraform (or CloudFormation), real Lambda code, real integration
tests, and a scripts/ directory you can run top to bottom. Every
tutorial has been deployed, tested green, and torn down cleanly on
LocalEmu.
The tutorials come in two shapes:
- Application patterns drive an end-to-end build with three scripts:
deploy.sh(Terraform or CloudFormation),test.sh(pytest), andteardown.sh. A couple of edge-case patterns substitutesetup.shfordeploy.shor drop the provisioning step entirely; the per-folder README calls out the difference. - Service demos are single-script walkthroughs: a
demo.shexercises the full scenario in one pass, andteardown.shcleans up.
| Folder | What it builds |
|---|---|
01-rest-api/ |
Five-route CRUD notes on API Gateway v2 + Lambda + DynamoDB |
02-scheduled-job/ |
Hourly EventBridge Scheduler Lambda checking Secrets Manager rotation age |
03-event-driven/ |
SNS fan-out with FilterPolicy to two SQS queues + two Lambdas (CloudFormation) |
04-image-pipeline/ |
S3 upload to Lambda (Pillow thumbnail) to SNS + CloudWatch |
05-batch-etl/ |
Step Functions Map over CSV rows with per-row Catch |
06-s3-guardrail/ |
CloudTrail to EventBridge to Lambda auto-remediation of public S3 buckets |
07-payment-ledger/ |
DynamoDB TransactWriteItems + Idempotency-Key + 5-way concurrent-debit race |
08-llm-gateway/ |
Guardrailed, cached, evaluated LLM gateway (API GW + Lambda + DDB + EB + SQS + CW) |
09-ci-cd/ |
Lambda handler unit tests against a LocalEmu service, runnable from any CI |
10-microservices/ |
SNS + 2 SQS + 2 DynamoDB-table mini e-commerce wired up via plain aws CLI |
| Folder | What it demonstrates | Required env |
|---|---|---|
11-cognito-demo/ |
User pool + client + user lifecycle | none |
12-kinesis-demo/ |
Stream create, PutRecord, GetRecords round-trip | none |
13-opensearch-demo/ |
Domain create (real OpenSearch container), index, search | none |
14-rds-demo/ |
Postgres + MySQL DB instances, psql + mysql clients, Python round-trip | RDS_DOCKER_BACKEND=1 |
15-ec2-demo/ |
RunInstances spins a real Docker container; SSH in via localemu ssh |
none |
16-ecs-demo/ |
Cluster + task definition + RunTask, real containers behind the API | none |
17-eks-demo/ |
EKS cluster via k3d, kubectl apply, real pod deploy |
none |
18-transit-gateway-demo/ |
Three VPCs, TGW + peering, connectivity matrix verified end-to-end | none |
19-iam-least-privilege/ |
Provably-minimum IAM policy via Sid-removal mutation testing | IAM_ENFORCEMENT=1 |
20-stepfunctions-saga/ |
Saga compensation across three failure injection points | none |
21-chaos-resilience/ |
Load test with zero-data-loss assertion under retry pressure | none |
All tutorials are tested end-to-end against both the pip install and the Docker image of LocalEmu.
- Python 3.10+ with
pytest,boto3,requests,Pillow(for the image-pipeline pattern) - Terraform 1.5+
- The AWS CLI
- LocalEmu running locally on port 4566 (
localemu start)
Application patterns (deploy.sh + test.sh + teardown.sh):
cd <tutorial-folder>
./scripts/deploy.sh local # or: aws
./scripts/test.sh local
./scripts/teardown.sh localA few application patterns substitute setup.sh for deploy.sh or
skip the provisioning step entirely; the per-folder README explains
the deviation. The local / aws argument flips a single Terraform
variable (or the --endpoint-url on CloudFormation patterns).
Nothing else changes between targets.
Service demos:
cd <tutorial-folder>
./scripts/demo.sh
./scripts/teardown.shA handful require LocalEmu to be started with a specific env var (see
the Service demos table above). The walkthrough's README.md repeats
the prerequisite at the top.
Apache 2.0.