Skip to content

Core Terraform Workflow Questions

Practice questions for Core Terraform Workflow topic in HashiCorp Certified: Terraform Associate (004). 32 questions covering this domain.

32 questions7 easy17 medium8 hard
Q1
medium

A practitioner clones a new Terraform project from version control. Which command should they run first in that directory?

Q2
hard

A practitioner must destroy only one specific Terraform-managed resource and leave the rest intact. Which command is intended for that targeted action...

Q3
medium

A team already reviewed and saved a plan file named tfplan. How should they apply exactly those approved actions?

Q4
easy

What does terraform validate do?

Q5
hard

A practitioner runs terraform plan -refresh-only after someone changed a managed resource outside Terraform. What does this mode do?

Q6
medium

A team wants a reviewed execution plan to be applied later exactly as approved. Which command should they run when creating the plan?

Q7
medium

A team wants terraform init to check for newer provider and module versions that still satisfy configured constraints. Which flag should they use?

Q8
medium

A CI pipeline should fail when Terraform files are not formatted correctly, but it must not rewrite files. Which command best fits?

Q9
medium

When is the -target option on terraform plan most appropriate?

Q10
medium

What kind of plan does terraform plan create when you do not use the -out option?

Q11
medium

A team changes backend settings and wants to copy existing state to the new backend during reinitialization. Which terraform init option fits that goa...

Q12
easy

Which statement about terraform init is correct?

Q13
easy

What does terraform fmt do without the -check option?

Q14
medium

A CI job runs terraform plan -detailed-exitcode. What does exit code 2 mean?

Q15
hard

A pipeline runs terraform plan -json and forgets to assign a required input variable. What is the documented consequence?

Q16
hard

Why should a saved plan file from terraform plan -out be treated as sensitive?

Q17
medium

An instance is degraded and should be replaced even though configuration has not changed. Which planning option expresses that intent?

Q18
hard

A locked-down CI job must verify provider checksums from the existing lock file but must not rewrite .terraform.lock.hcl. Which init setting should it...

Q19
easy

Before terraform plan compares configuration to prior state in normal mode, what does it do by default?

Q20
medium

Why should terraform plan -refresh=false be used cautiously?

Sign in to see all 32 questions

Create a free account to browse all questions — completely free during our launch phase.