Terraform Associate Certification Q131-Q140

  1. Terraform Associate Certification Q1-Q10
  2. Terraform Associate Certification Q11-Q20
  3. Terraform Associate Certification Q21-Q30
  4. Terraform Associate Certification Q31-Q40
  5. Terraform Associate Certification Q41-Q50
  6. Terraform Associate Certification Q51-Q60
  7. Terraform Associate Certification Q61-Q70
  8. Terraform Associate Certification Q71-Q80
  9. Terraform Associate Certification Q81-Q90
  10. Terraform Associate Certification Q91-Q100
  11. Terraform Associate Certification Q101-Q110
  12. Terraform Associate Certification Q111-Q120
  13. Terraform Associate Certification Q121-Q130
  14. Terraform Associate Certification Q131-Q140
  15. Terraform Associate Certification Q141-Q151

Please Subscribe to Access the Premium Content

The remaining premium contents are locked. Please subscribe to the monthly newsletter to unlock the content for free.

Loading...

131. You decide to move a Terraform state file to Amazon S3 from another location. You write the code below into a file called backend.tf.
Which command will migrate your current state file to the new S3 remote backend?

A. terraform state
B. terraform init
C. terraform refresh
D. terraform push

Answer

B


132. You want to tag multiple resources with a string that is a combination of a generated random_id and a variable.
How should you use the same value in all these resources without repeating the random_id and variable in each resource?

A. Local values
B. Data source
C. Modules
D. Outputs

Answer

A


133. Which of the following is not a benefit of adopting infrastructure as code?

A. Interpolation
B. Reusability of code
C. Versioning
D. Automation

Answer

A


134. Module version is required to reference a module on the Terraform Module Registry.

A. True
B. False

Answer

B


135. While deploying a virtual machine, the first launch user_data script fails due to race condition with another resource deployed during the same Terraform run.
What is the least disruptive method to correct the issue?

A. Run terraform taint against the virtual machine’s resource name, then terraform apply
B. Restart the virtual machine from the cloud portal
C. Run terraform apply again
D. Run terraform destroy then terraform apply

Answer

A


136. The public Module Registry is free to use.

A. True
B. False

Answer

A


137. Both Terraform Cloud and Terraform Enterprise support policy as code (Sentinel).

A. True
B. False

Answer

A


138. You want to define multiple data disks as nested blocks inside the resource block for a virtual machine.
What Terraform feature would help you define the blocks using the values in a variable?

A. Local values
B. Collection functions
C. Dynamic blocks
D. Count arguments

Answer

C


139. Which of the following module source paths does not specify a remote module?

A. source = “./modules/consul”
B. source = “[email protected]:hashicorp/example.git”
C. source = “github.com/hashicorp/example”
D. source = “hashicorp/consul/aws”

Answer

A


140. You have a list of numbers that represents the number of free CPU cores on each virtual cluster:

numcpus = [ 18, 3, 7, 11, 2 ]

What Terraform function could you use to select the largest number from the list?

A. max(numcpus)
B. ceil(numcpus)
C. top(numcpus)
D. high[numcpus]

Answer

A


Leave a Comment

Your email address will not be published. Required fields are marked *


Scroll to Top