Free TA-002-P Exam Braindumps

Pass your HashiCorp Certified: Terraform Associate exam with these free Questions and Answers

Page 4 of 19
QUESTION 11

- (Exam Topic 4)
Select the answer below that completes the following statement: Terraform Cloud can be managed from the CLI but requires ______?

  1. A. an API token
  2. B. a TOTP token
  3. C. a username and password
  4. D. authentication using MFA

Correct Answer: A
API and CLI access are managed with API tokens, which can be generated in the Terraform Cloud UI. Each user can generate any number of personal API tokens, which allow access with their own identity and permissions. Organizations and teams can also generate tokens for automating tasks that aren't tied to an individual user.

QUESTION 12

- (Exam Topic 2)
You have created a custom variable definition file testing.tfvars. How will you use it for provisioning infrastructure?

  1. A. terraform apply -var-state-file ="testing.tfvars"
  2. B. terraform plan -var-file="testing.tfvar"
  3. C. terraform apply -var-file="testing.tfvars"
  4. D. terraform apply var-file="testing.tfvars"

Correct Answer: C
https://www.terraform.io/docs/configuration/variables.html

QUESTION 13

- (Exam Topic 1)
You have never used Terraform before and would like to test it out using a shared team account for a cloud provider. The shared team account already contains 15 virtual machines (VM). You develop a Terraform configuration containing one VM, perform terraform apply, and see that your VM was created successfully.
What should you do to delete the newly-created VM with Terraform?

  1. A. The Terraform state file contains all 16 VMs in the team accoun
  2. B. Execute terraform destroy and select the newly-created VM.
  3. C. The Terraform state file only contains the one new V
  4. D. Execute terraform destroy.
  5. E. Delete the Terraform state file and execute Terraform apply.
  6. F. Delete the VM using the cloud provider console and terraform apply to apply the changes to the Terraform state file.

Correct Answer: B
You develop a Terraform configuration containing one VM, perform terraform apply, and see that your VM was created successfully. read the question carefully "Terraform configuration containing one VM, perform terraform apply" so only one VM is in state file.

QUESTION 14

- (Exam Topic 1)
When you initialize Terraform, where does it cache modules from the public Terraform Module Registry?

  1. A. On disk in the /tmp directory
  2. B. In memory
  3. C. On disk in the .terraform sub-directory
  4. D. They are not cached

Correct Answer: C

"A hidden .terraform directory, which Terraform uses to manage cached provider plugins and modules, record which workspace is currently active, and record the last known backend configuration in case it needs to migrate state on the next run. This directory is automatically managed by Terraform, and is created during initialization." https://www.terraform.io/cli/init

QUESTION 15

- (Exam Topic 4)
You have configured an Auto Scaling group in AWS to automatically scale the number of instances behind a load balancer based on the instances CPU utilization. The instances are configured using a Launch Configuration. You have observed that the Auto Scaling group doesn't successfully scale when you apply
changes that require replacing the Launch Configuration. Why is this happening?

  1. A. You need to configure an explicit dependency for the Auto Scaling group using the depends_on meta-parameter.
  2. B. You need to configure an explicit dependency for the Launch Configuration using the depends_on meta-parameter.
  3. C. You need to configure the Auto Scaling group's create_before_destroy meta-parameter.
  4. D. You need to configure the Launch Configuration's create_before_destroy meta-parameter.

Correct Answer: D
https://www.terraform.io/docs/providers/aws/r/launch_configuration.html#using-withautoscaling-groups

Page 4 of 19

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