What does Terraform use the .terraform.lock.hc1 file for?
Answer(s): B
The .terraform.lock.hcl file is a new feature in Terraform 0.14 that records the exact versions of each provider used in your configuration. This helps ensure consistent and reproducible behavior across different machines and runs.
Why does this backend configuration not follow best practices?
Answer(s): C
This is a bad practice, as it exposes your credentials to anyone who can access your configuration files or state files. You should use environment variables, credential files, or other mechanisms to provide credentials to Terraform.
Module variable assignments are inherited from the parent module and you do not need to explicitly set them.
Module variable assignments are not inherited from the parent module and you need to explicitly set them using the source argument. This allows you to customize the behavior of each module instance.
What does Terraform not reference when running a terraform apply -refresh-only ?
Answer(s): D
When running a terraform apply -refresh-only, Terraform does not reference the configuration files, but only the state file, credentials, and cloud provider. The purpose of this command is to update the state file with the current status of the real resources, without making any changes to them1.
Which of the following is not a valid Terraform variable type?
This is not a valid Terraform variable type. The other options are valid variable types that can store different kinds of values2.
Post your Comments and Discuss HashiCorp Terraform-Associate-004 exam dumps with other Community members:
G Commented on July 31, 2025 Very helpful exam dumps pdf for higher success rates AUSTRALIA
pooja Commented on July 31, 2025 I am reading these questions and found them really helpful to understand . Anonymous
Pooja Commented on July 31, 2025 Very nice set of questions for preparation of AZ-104 Anonymous
Den Commented on July 30, 2025 answers have explanation which really helps to understand the topic Anonymous