Skill Roadmap

Terraform

Terraform is HashiCorp's infrastructure-as-code tool for defining, provisioning, and managing cloud infrastructure through configuration files. This roadmap walks you from HCL and providers through resources, state management, modules, testing, and scaling Terraform across a team.

What skills does a Terraform engineer need?

Infrastructure as code, applied to a real cloud provider

Terraform is an infrastructure-as-code (IaC) tool made by HashiCorp: you describe servers, databases, networking, and DNS records in configuration files, then create or destroy that infrastructure with a single command. It works across major cloud providers including AWS, GCP, and Azure, which means Terraform skills are rarely learned in isolation — you'll need working knowledge of at least one cloud provider's core services alongside it.

Day to day, that means writing HashiCorp Configuration Language (HCL), understanding how resources, variables, and outputs fit together, and being disciplined about state management — since a mismanaged state file is the most common source of real production incidents.

As teams scale, Terraform work grows into modules, CI/CD pipelines, automated testing, and security/compliance scanning — the difference between running `terraform apply` from a laptop and running infrastructure as code safely at organisation scale.

The Terraform Roadmap

Work through these in order — the core workflow first, then state, modules, and team-scale tooling

STEP 1
Terraform logo

Introduction

Understand what Terraform is for and how infrastructure as code differs from configuration as code before writing anything.

What is Terraform? Usecases and Benefits Installing Terraform CaC vs IaC
STEP 2

Providers & Project Initialization

Providers are the plugins that let Terraform talk to a specific cloud or service.

Configuring Providers Provider Versions
STEP 3

HashiCorp Configuration Language (HCL)

The declarative language every Terraform file is written in.

What is Infrastructure as Code? What is HCL? Basic Syntax
STEP 4

Resources

Resources are the building blocks that map an HCL block to a real piece of infrastructure.

Resource Behavior Resource Lifecycle
Meta Arguments
depends_on count for_each provider lifecycle
STEP 5

Variables, Locals & Outputs

Parameterise configuration and expose values so modules and pipelines can consume them.

Input Variables
Type Constraints Environment Variables Variable Definition File Validation Rules
Local Values
Outputs
Output Syntax Sensitive Outputs Preconditions
STEP 6

Format, Validate & Deploy

The core Terraform workflow: check the config, preview the change, apply it, then clean up.

Format & Validate
terraform fmt terraform validate TFLint
Deployment
terraform plan terraform apply -replace option
Inspect / Modify
graph list output
Clean Up
terraform destroy
STEP 7

State Management

The state file is Terraform's source of truth — mismanaging it is the most common cause of real incidents.

State Remote State State Locking Import Existing Resources Splitting State Files Versioning Sensitive Data Best Practices for State
Commands
show rm mv state pull / push state replace-provider state force-unlock
STEP 8

Modules, Provisioners & Data Sources

Package reusable infrastructure into modules, and reach for provisioners only when a resource genuinely needs one.

Modules
Root vs Child Modules Published Modules Usage Creating Local Modules Inputs / Outputs Modules Best Practices Basic / Advanced Commands
Provisioners
When to Use? Creation / Destroy Time file provisioner local-exec provisioner remote-exec provisioner Custom Provisioners
Data Sources Template Files
STEP 9

CI/CD Integration & Workspaces

Run plan and apply from a pipeline instead of a laptop, and separate environments with workspaces.

STEP 10

Testing

Verify modules behave correctly before they reach production, at several levels of depth.

Unit Testing Contract Testing Integration Testing End to End Testing Testing Modules
STEP 11

Scaling, Compliance & Security

What changes once one engineer's state file becomes a team's shared infrastructure.

Scaling Terraform
Splitting Large State Parallelism Deployment Workflow Terragrunt Infracost Secret Management
Compliance & Security
STEP 12

HCP Terraform

HashiCorp's managed platform for teams that need shared state, policy enforcement, and run automation without hosting it themselves.

What and when to use HCP? Enterprise Features Authentication Workspaces VCS Integration Run Tasks Version Management

GitHub Projects

Real, buildable projects to put on your own GitHub

Frequently Asked Questions

Common questions from people starting out with Terraform

Is Terraform free to use?

The core Terraform CLI is free and open source under the Business Source License. HCP Terraform (formerly Terraform Cloud) adds a managed platform on top, with a free tier and paid plans for larger teams that need remote state, policy enforcement, and run automation.

What's the difference between Terraform and Ansible?

Terraform is primarily a provisioning tool — it creates and tracks the lifecycle of infrastructure using a state file. Ansible is a configuration management tool aimed at configuring software on servers that already exist. Many teams use both: Terraform to provision, Ansible to configure.

How does Terraform compare to CloudFormation?

CloudFormation is AWS-specific and tightly integrated with that ecosystem, while Terraform is cloud-agnostic and works across AWS, GCP, Azure, and many other providers through the same HCL syntax and workflow.

Why does the state file matter so much?

Terraform's state file is its record of what infrastructure it's actually managing and how that maps to your configuration. If it's lost, corrupted, or edited manually without care, Terraform can lose track of real resources or try to recreate things that already exist — which is why remote state and locking matter early, not just at scale.

Do I need to learn a specific cloud provider first?

Terraform syntax is provider-agnostic, but you'll need working knowledge of at least one cloud's core services — compute, networking, storage — to write meaningful resources. Most learners pick whichever provider they already have free-tier access to, commonly AWS.

How do I prepare for a Terraform / DevOps interview?

Be comfortable explaining state and why remote state with locking matters, know the plan/apply/destroy workflow cold, understand modules and when to write versus reuse one, and have a project — ideally with CI/CD and a security scan — you can walk through in detail.

Track complete

From your first `terraform apply` to managing state and modules at team scale — that's the core of what employers expect from a Terraform engineer. Keep building, and let the cloud provider and pipeline tools you use most pull you toward the next roadmap.

Where next?

Keep exploring by domain or drill into a single skill