HashiCorp TA-002-P Exam
HashiCorp Certified: Terraform Associate (Page 5 )

Updated On: 1-Feb-2026

What information does the public Terraform Module Registry automatically expose about published modules?

  1. Required input variables
  2. Optional inputs variables and default values
  3. Outputs
  4. All of the above
  5. None of the above

Answer(s): D

Explanation:

"The registry extracts information about the module from the module's source. The module name, provider, documentation, inputs/outputs, and dependencies are all parsed and available via the UI or API, as well as the same information for any submodules or examples in the module's source repository."


Reference:

https://www.terraform.io/registry/modules/publish



If a module uses a local variable, you can expose that value with a terraform output.

  1. True
  2. False

Answer(s): A

Explanation:

Output values are like function return values.


Reference:

https://www.terraform.io/docs/language/values/locals.html
https://www.terraform.io/docs/language/values/outputs.html



You should store secret data in the same version control repository as your Terraform configuration.

  1. True
  2. False

Answer(s): B


Reference:

https://blog.gruntwork.io/a-comprehensive-guide-to-managing-secrets-in-your-terraform-code-1d586955ace1



Which of the following is not a valid string function in Terraform?

  1. split
  2. join
  3. slice
  4. chomp

Answer(s): C


Reference:

https://www.terraform.io/language/functions



You have provisioned some virtual machines (VMs) on Google Cloud Platform (GCP) using the gcloud command line tool. However, you are standardizing with Terraform and want to manage these VMs using Terraform instead.
What are the two things you must do to achieve this? (Choose two.)

  1. Provision new VMs using Terraform with the same VM names
  2. Use the terraform import command for the existing VMs
  3. Write Terraform configuration for the existing VMs
  4. Run the terraform import-gcp command

Answer(s): B,C

Explanation:

You should create the equivalent configuration first, and then run import to load it on the state file.



Viewing page 5 of 91
Viewing questions 21 - 25 out of 449 questions



Post your Comments and Discuss HashiCorp TA-002-P exam prep with other Community members:

Join the TA-002-P Discussion