Designing Production-Ready AWS Infrastructure with Terraform
Network boundaries, state isolation, reviewed changes, and recovery planning for a hypothetical AWS workload.
Designing secure, scalable, and cost-conscious cloud environments built for reliability, automation, and long-term growth.
A shared administrator role across every environment collapses the value of separate VPCs. Isolation has to survive a leaked credential, a bad apply, and an expired certificate.
Most incidents travel through identity, DNS, or a dependency that was never drawn. Public and private placement only helps if security groups, routes, and endpoints match the intended path.
Backups, snapshots, and multi-AZ flags are configuration. Recovery is a rehearsed procedure with observed time, data loss, and dependency order.
Start with blast radius and identity, then place networks, then place compute and data. Accounts or subscriptions, IAM boundaries, and environment isolation decide how much a single mistake can cost. Topology comes after those constraints, not before.
A typical internet-facing workload keeps the load balancer in public subnets and application and data tiers in private subnets across at least two availability zones. Outbound access, if required, is explicit—NAT, private endpoints, or neither. On Azure the same isolation is a VNet, NSGs, a private AKS API when required, and private endpoints to data services. Google Cloud is additional platform familiarity, not a third identical control plane. State, secrets, and backup restoration are part of the architecture, not later operations work.
Public edge. Internet-facing load balancer in public subnets. This is the only intended inbound path.
Illustrative AWS-shaped topology. Azure uses equivalent ideas (VNet, subnets, load balancer, private data) with different service names and identity primitives.
State and modules. Isolate state backends per environment. Modules should encode one lifecycle. Drift detection is useful only when someone owns the result.
Illustrative lifecycle. A privileged apply should consume the reviewed plan. Shared state across environments is an access-control failure.
Development, staging, and production should not share blast radius, state backends, or break-glass identities. Promotion moves artifacts and reviewed plans, not ad-hoc copies of live resources.
Application and data tiers belong in private subnets. Security groups should allow the application port from the load-balancer group, not from the internet.
Plan against the target environment identity, apply the reviewed plan, and record how to revert or correct the change. Drift that nobody owns is just undocumented production.
DNS, certificates, secrets, queue consumers, and backup destinations fail independently of the VPC drawing. Document them as first-class components.
Workload identity, private endpoints, and least-privilege roles decide who can reach data stores. A private subnet with a role that can assume production is not isolation.
Network and identity change slower than application modules. Separate state and pipelines so an application change cannot rewrite shared routing.
Cross-zone traffic, extra NAT or load-balancer capacity, and replicated data stores have a price. Choose recovery objectives before choosing topology.
NAT is simple and can become expensive at volume. VPC endpoints or Private Link reduce internet egress for supported services but add hourly charges and more Terraform surface.
Hub-and-spoke VNets, NSGs, and managed identities are not drop-in replacements for TGW, security groups, and IAM roles. Port patterns, not YAML.
A small product team runs a public HTTPS API. An application load balancer in public subnets forwards to containers in private subnets across two availability zones. The managed database and cache are private. Terraform state lives in a locked, encrypted backend per environment. The team tests database restore quarterly in an isolated account. This is an educational layout, not a client system or a measured production result.
A single apply can destroy production while intending to change development. State isolation is an access-control decision.
Temporary public access becomes permanent. Use private connectivity and a documented break-glass path instead.
A snapshot that has never been restored is an untested assumption. Restore order, secrets, and DNS cutover are part of the plan.
Follow delivery, runtime, and telemetry on a hypothetical VPC without creating cloud resources.
Explore the educational architecture →Network boundaries, state isolation, reviewed changes, and recovery planning for a hypothetical AWS workload.
Isolate blast radius with accounts, identities, state, and promotion of the same artifact—not a shared admin role with three VPC names.
Attribute spend, remove idle waste, and treat unused production capacity as a named reliability choice—not an automatic saving.
Architecture, delivery, identity, and recovery—not a tool list. No fabricated case studies, no implied retainer.