nerdexam
HashiCorp

TA-002-P · Question #341

The Terraform CLI will print output values from a child module after running terraform apply.

The correct answer is A. True. After terraform apply successfully provisions or updates resources, the Terraform CLI prints the output values of the root module, which includes any output values exposed by its child modules. This provides immediate visibility into important information from your…

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

Question

The Terraform CLI will print output values from a child module after running terraform apply.

Options

  • ATrue
  • BFalse

How the community answered

(49 responses)
  • A
    88% (43)
  • B
    12% (6)

Why each option

After `terraform apply` successfully provisions or updates resources, the Terraform CLI prints the output values of the root module, which includes any output values exposed by its child modules. This provides immediate visibility into important information from your infrastructure.

ATrueCorrect

When `terraform apply` completes successfully, the Terraform CLI displays the output values of the root module. If a child module defines output values and the root module exposes them (e.g., by referencing them in its own output blocks), those values will indeed be printed to the console after the apply operation.

BFalse

Terraform explicitly prints output values after a successful `apply` to provide important information about the deployed infrastructure, including those from child modules if they are exposed.

Concept tested: Terraform module outputs and apply

Source: https://developer.hashicorp.com/terraform/language/values/outputs

Topics

#terraform apply#module outputs#CLI output

Community Discussion

No community discussion yet for this question.

Full TA-002-P Practice