nerdexam
HashiCorp

TERRAFORM-ASSOCIATE-004 · Question #57

A module can always refer to all variables declared in its parent module.

The correct answer is B. False. This is False. Terraform modules are encapsulated - a child module cannot directly access variables declared in its parent module. All data passed into a module must be explicitly provided as input variables when calling the module. This encapsulation is by design, ensuring modul

Submitted by suresh_in· Apr 18, 2026Work with Terraform Modules

Question

A module can always refer to all variables declared in its parent module.

Options

  • ATrue
  • BFalse

How the community answered

(31 responses)
  • A
    13% (4)
  • B
    87% (27)

Explanation

This is False. Terraform modules are encapsulated - a child module cannot directly access variables declared in its parent module. All data passed into a module must be explicitly provided as input variables when calling the module. This encapsulation is by design, ensuring modules remain reusable and self-contained regardless of the context they are called from.

Topics

#Terraform Modules#Module Inputs#Variable Scope#Module Communication

Community Discussion

No community discussion yet for this question.

Full TERRAFORM-ASSOCIATE-004 Practice