nerdexam
HashiCorp

TA-002-P · Question #237

Which of the following actions are performed during a terraform init?

The correct answer is A. Initializes downloaded and/or installed providers B. Initializes the backend configuration D. Download the declared providers which are supported by HashiCorp. 'terraform init' performs three key tasks: (A) initializes providers after downloading them, (B) initializes the backend so Terraform knows where to store state, and (D) downloads the required provider plugins declared in your configuration. Option C is incorrect - provisioning…

Use the Terraform CLI (terraform plan, apply, destroy, fmt, init, validate, workspace, import, taint, providers, output)

Question

Which of the following actions are performed during a terraform init?

Options

  • AInitializes downloaded and/or installed providers
  • BInitializes the backend configuration
  • CProvisions the declared resources in your configuration
  • DDownload the declared providers which are supported by HashiCorp

How the community answered

(38 responses)
  • A
    89% (34)
  • C
    11% (4)

Explanation

'terraform init' performs three key tasks: (A) initializes providers after downloading them, (B) initializes the backend so Terraform knows where to store state, and (D) downloads the required provider plugins declared in your configuration. Option C is incorrect - provisioning resources is the job of 'terraform apply', not 'terraform init'. Init prepares the working directory but makes no changes to real infrastructure.

Topics

#terraform init#CLI commands#providers#backend

Community Discussion

No community discussion yet for this question.

Full TA-002-P Practice