TF-004 Understand Terraform basics Practice Question
A developer is new to Terraform and wants to understand the core workflow. Which sequence of commands correctly represents the basic Terraform workflow?
⚠ Common exam trap
HashiCorp often tests the misconception that `terraform plan` is optional or that `terraform init` can be skipped if providers are already cached, but the exam requires strict adherence to the documented workflow sequence.
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 init, terraform plan, terraform apply
The basic Terraform workflow follows a strict three-step sequence: `terraform init` to initialize the working directory and download required providers/modules, `terraform plan` to preview the changes Terraform will make against the current state, and `terraform apply` to execute the planned changes. Skipping `init` or `plan` would either fail due to missing providers or apply changes without a reviewable execution plan, violating the standard workflow.
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 init, terraform apply
Why it's wrong here
While `terraform apply` can implicitly generate an execution plan, this sequence is incorrect because it bypasses the crucial step of explicitly reviewing the proposed infrastructure changes. Omitting `terraform plan` means a developer cannot inspect the exact actions Terraform intends to take before committing them, which is a significant risk for unintended modifications or resource deletions in a production environment.
- ✗
terraform plan, terraform init, terraform apply
Why it's wrong here
This order is fundamentally incorrect because `terraform plan` requires the backend and provider plugins to be initialized before it can generate an execution plan. Running `terraform plan` first would fail, as Terraform would not yet know how to interact with the target cloud provider or manage its state, making `terraform init` a prerequisite for any subsequent operations like planning or applying.
- ✓
terraform init, terraform plan, terraform apply
Why this is correct
This sequence represents the standard and recommended Terraform core workflow for provisioning infrastructure. `terraform init` first prepares the working directory by downloading necessary provider plugins and initializing the backend. Subsequently, `terraform plan` generates a detailed execution plan outlining all proposed changes, allowing for review, before `terraform apply` then executes that plan to create, update, or delete resources.
- ✗
terraform validate, terraform plan, terraform destroy
Why it's wrong here
This sequence is incorrect for a basic infrastructure provisioning workflow because `terraform validate` is an optional step, primarily for syntax and configuration checks, not a mandatory part of the core creation process. More critically, `terraform destroy` is used for de-provisioning and tearing down existing infrastructure, not for the initial setup or modification that a new developer would typically be learning.
Go deeper
Related to this question
About these practice questions
This TF-004 question is part of Courseiva's 428-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
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.