Skip to main content

31 posts tagged with "Terraform"

Infrastructure as Code with Terraform

View All Tags

Terraform on Azure — Resource Groups, VNets, and VMs

· 5 min read
Goel Academy
DevOps & Cloud Learning Hub

If you have been following this series, every example so far has used AWS. But Terraform is cloud-agnostic, and Azure is one of the most well-supported providers in the ecosystem. The AzureRM provider has 700+ resource types covering everything from VMs to Cosmos DB to AKS. This post walks you through Azure fundamentals with Terraform — authentication, resource groups, networking, and a full Linux VM deployment.

Terraform Remote State with S3 and DynamoDB — Team Collaboration

· 6 min read
Goel Academy
DevOps & Cloud Learning Hub

The moment a second person runs terraform apply on the same project, local state files become a disaster. One person's laptop has the truth, the other has a stale copy, and the next apply either duplicates resources or deletes them. Remote state fixes this by storing your state in a shared location with locking, so two people can never write to it simultaneously. For AWS teams, the S3 + DynamoDB pattern is the industry standard.

Build a Complete AWS VPC with Terraform — Step by Step

· 6 min read
Goel Academy
DevOps & Cloud Learning Hub

Every AWS workload starts with a VPC. Click through the console once and you might get it right. Click through it for the fifth project and you will definitely get something wrong — a missing route, a misconfigured NAT gateway, a subnet that accidentally got a public IP. Terraform eliminates that problem. You define the network once, version it, and deploy identical VPCs across accounts, regions, and environments. This post builds a production-ready VPC from the ground up.

Terraform Workspaces — Manage Dev, Staging, and Production

· 6 min read
Goel Academy
DevOps & Cloud Learning Hub

Your Terraform code works perfectly in dev. Now you need the same infrastructure in staging and production, but with different instance sizes, different CIDR blocks, and different resource counts. You could copy the entire directory three times. Or you could use workspaces — Terraform's built-in mechanism for managing multiple instances of the same configuration with isolated state.

Terraform Modules — Reusable Infrastructure Components

· 6 min read
Goel Academy
DevOps & Cloud Learning Hub

You have been writing Terraform for a while now. Your main.tf started at 50 lines, grew to 200, then 600, and now nobody wants to touch it. Worse, every new project copies the same VPC, subnet, and security group blocks with minor tweaks. Modules solve both problems: they let you package infrastructure into self-contained, versioned, shareable components — like functions in a programming language.

Terraform Expressions — Conditionals, Loops, and Dynamic Blocks

· 7 min read
Goel Academy
DevOps & Cloud Learning Hub

Terraform's HCL is not a general-purpose programming language, but it is far more powerful than a static config file. You can conditionally create resources, loop over lists and maps, generate repeated blocks dynamically, and build complex data transformations — all without leaving your .tf files. These expressions are what turn a one-off configuration into a reusable platform.