← All projects

Three-tier AWS platform in Terraform

In build — target Aug 30, 2026. The plan below is complete; real configs, command outputs, screenshots and the troubleshooting log land here as the build finishes.

Terraform AWS VPC ALB Auto Scaling RDS tflint

What this project builds

The standard production AWS shape, expressed entirely as code from an empty account: a multi-AZ VPC with public and private subnets across two availability zones, an Application Load Balancer in the public tier, application servers in an Auto Scaling group in the private tier, and RDS behind them.

Architecture

  • Network — VPC with public + private subnets in two AZs; internet gateway for the public tier, NAT for the private.
  • Traffic — ALB in the public subnets is the only entry point.
  • Compute — app servers in an Auto Scaling group, private subnets only, bootstrapped by userdata.
  • Data — RDS in the private tier; only the app security group may reach it.
  • Security — security groups chained tier to tier: internet → ALB → app → DB, nothing skips a hop.

How it will be built

  • Terraform split by concern: network.tf, security.tf, compute.tf, database.tf, with variables.tf and a terraform.tfvars.example.
  • Remote state (S3 backend) added in phase two — state is the database of IaC and deserves the same care.
  • Linted with tflint; the full plan → apply → verify → destroy lifecycle exercised, with a same-day teardown script so the whole environment costs under USD 2.

Why it matters

I run production infrastructure daily — this project expresses that experience in the industry-standard IaC dialect, provable from an empty account to a working platform and back to zero.