roadmap
- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
Explain how Terraform turns HCL into real infrastructure and keeps it in sync, at the depth interviews probe. Covers IaC principles, state, modules, plan/apply, tests, HCP Terraform and policy gates.
299 of 299 questions in your plan: 0 known, 0 in progress, 0 due, 0 skipped, 299 new. 0 cut, outside your plan.
Interviewers rarely set aside time for Terraform alone; it is folded into the infrastructure conversation of DevOps, SRE, platform and cloud loops. It arrives either as a module written at home beforehand or as a plan output pasted into the call with one question: what is this about to do? Backend loops reach it mainly when a résumé names it.
The questions are incidents in miniature. Subnets are managed with count, someone deletes the second entry, and the plan wants to recreate every subnet after it: why, and what does for_each change? A variable marked sensitive no longer prints, so where can the password still be read? Two pipelines apply to the same state at once: what stops them, and what do you do when a lock outlives its run? A refactor renamed a resource and the plan now shows a destroy and a create: which block says it is the same object?
Seniority shows in how far the answer reaches past the command. At the junior end, a correct account of the model carries the answer: what state records, what plan compares it against, why a data source reads where a resource owns. Higher up, the subject is an estate: where to split state so a mistake in staging cannot touch production, how to ship a breaking module version to teams that pin it, and how to recover when state and reality disagree.
The opening module is tool-neutral on purpose. Reconciling toward a desired state, drift and the theory of state sit behind most Terraform questions, and meeting them before the syntax lets an answer say why Terraform behaves as it does. The comparison with Pulumi closes the stretch: the same model in a general-purpose language shows which habits belong to infrastructure as code and which to HCL.
The Terraform module starts at the single block and widens from there. Resources and their meta-arguments come first, then the providers that turn a block into API calls. State and backends follow while that model is fresh, because import, refactoring, locking and leaked secrets are all questions about the mapping between a block and a real object. Inputs, outputs and modules make one configuration reusable, and the plan/apply workflow moves the commands into CI, then adds the tests, the wrapper and the cost check a pipeline runs. HCP Terraform closes the module by handing those runs to a managed service.
The last module turns from writing configuration to checking it, and starts with the file a gate reads rather than with a tool: the planned values a plan exposes, the attributes unknown until apply that no rule can judge yet, and conditions that span resources, such as a bucket and the separate resource that blocks public access to it. Writing rules and deciding what blocks an apply, including how a suppression is recorded, come before the ready-made scanners such as Checkov, which are easier to judge once you know what a rule can see in a plan.
Set level with care on this page: the bottom of its range asks what `plan` compares, the top asks where state is split and who may apply to production, and drilling the wrong end rehearses the wrong conversation. Two weeks out, cut the level range down to your own band, drop should know and nice to know from importance, and give the freed hours to State & Backends, where follow-ups tend to land. Engineers who have only applied a team's existing modules usually know the commands and not the state: open a scratch backend and break it on purpose, renaming a resource, importing one created by hand, killing an apply mid-run and clearing the lock it leaves. Security engineers headed for infrastructure-code review want Policy Gates most, yet they should let study order run by topics rather than jump ahead, since a rule over a plan needs someone who can read one. With a few months, build a small estate as you read: two environments in separate states and a pipeline that saves the plan, scans it and applies only that file. The plan teaches the tool, not the cloud it writes to: what an IAM trust policy grants, how a VPC routes traffic, why a security group needs no return rule. Those questions come up in the same loops, and the [AWS roadmap](/roadmaps/aws) covers them.
Set level with care on this page: the bottom of its range asks what plan compares, the top asks where state is split and who may apply to production, and drilling the wrong end rehearses the wrong conversation. Two weeks out, cut the level range down to your own band, drop should know and nice to know from importance, and give the freed hours to State & Backends, where follow-ups tend to land.
Engineers who have only applied a team's existing modules usually know the commands and not the state: open a scratch backend and break it on purpose, renaming a resource, importing one created by hand, killing an apply mid-run and clearing the lock it leaves. Security engineers headed for infrastructure-code review want Policy Gates most, yet they should let study order run by topics rather than jump ahead, since a rule over a plan needs someone who can read one. With a few months, build a small estate as you read: two environments in separate states and a pipeline that saves the plan, scans it and applies only that file.
The plan teaches the tool, not the cloud it writes to: what an IAM trust policy grants, how a VPC routes traffic, why a security group needs no return rule. Those questions come up in the same loops, and the AWS roadmap covers them.