TF-004 Understand Terraform's purpose Practice Question
A platform team currently provisions servers by filing tickets that an operations group fulfills manually over several days. Leadership wants developers to describe the desired end state of that infrastructure in version-controlled files so the tooling itself figures out which resources to create, modify, or remove. Which characteristic of Terraform directly supports this goal?
⚠ Common exam trap
The trap here is assuming Terraform executes configuration top-to-bottom like a script, when ordering actually comes from the dependency graph derived from references.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
Terraform is declarative, so you define the desired end state and it computes the actions needed to reach it.
The team needs files that describe the intended end state of infrastructure rather than a manual sequence of provisioning steps. A declarative configuration language fits that need because Terraform compares desired state with recorded state, builds a dependency graph, and produces an execution plan of create, update, and destroy actions. Procedural scripting, embedded credentials, and host-installed agents do not deliver that outcome.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✓
Terraform is declarative, so you define the desired end state and it computes the actions needed to reach it.
Why this is correct
Terraform's declarative model means configuration expresses the intended end state rather than the sequence of API calls, and the core engine builds a dependency graph and diffs current state against desired state to decide what to create, update, or destroy. That is exactly what removes the manual ticket-driven step-by-step provisioning described here.
- ✗
Terraform stores credentials in the configuration so provisioning runs unattended.
Why it's wrong here
Terraform configuration should never embed long-lived credentials; authentication is supplied through provider configuration, environment variables, or dynamic credentials. Even if credentials were handled well, unattended execution is not what lets the tool determine which resources to change. The stated goal is describing desired end state, which this option does not address.
- ✗
Terraform applies changes through a configuration management agent installed on each managed host.
Why it's wrong here
Terraform is agentless: it talks to provider APIs over the network and does not require software running on managed hosts. Configuration management agents belong to tools such as Chef or Puppet. Installing agents would not give the team a desired-state description of cloud resources, so it fails to meet the scenario's requirement.
- ✗
Terraform is procedural, so engineers write ordered scripts that call each provider API in sequence.
Why it's wrong here
Terraform is not a procedural scripting language; you do not hand-author the ordered sequence of API calls. The engine derives ordering from resource references in the dependency graph. Writing imperative steps would reintroduce the manual, order-sensitive work the platform team is trying to eliminate, so this does not satisfy the requirement.
Go deeper
Related to this question
About these practice questions
One of 434 original TF-004 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →
JA
Written and reviewed by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
Last reviewed September 2026 · checked against the official HashiCorp exam blueprint
This TF-004 practice question is part of Courseiva's free HashiCorp certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the TF-004 exam.