Exit demo TERRAFORM-ASSOCIATE-003 HashiCorp Certified: Terraform Associate (003) (HCTA0-003) PDF format · free preview

HashiCorp TERRAFORM-ASSOCIATE-003 - Questions & Answers

Free preview · every answer includes a full explanation

Product page: https://prepkeys.com/terraform-associate-003.html

Question 1
Single choice

If a module declares a variable with a default, that variable must also be defined within the module.

A.

True

B.

False

Question 2
Single choice

Your security team scanned some Terraform workspaces and found secrets stored in a plaintext in state files.

How can you protect sensitive data stored in Terraform state files?

A.

Delete the state file every time you run Terraform

B.

Store the state in an encrypted backend

C.

Edit your state file to scrub out the sensitive data

D.

Always store your secrets in a secrets.tfvars file.

Question 3
Single choice

What does the default "local" Terraform backend store?

A.

tfplan files

B.

Terraform binary

C.

Provider plugins

D.

State file

Question 4
Single choice

What is the name assigned by Terraform to reference this resource?

A.

dev

B.

azurerm_resource_group

C.

azurerm

D.

test

Question 5
Single choice

You have declared an input variable called environment in your parent module.

What must you do to pass the value to a child module in the configuration?

A.

Add node_count = var.node_count

B.

Declare the variable in a terraform.tfvars file

C.

Declare a node_count input variable for child module

D.

Nothing, child modules inherit variables of parent module

Question 6
Multiple choice

You have declared a variable called var.list which is a list of objects that all have an attribute id.

Which options will produce a list of the IDs? (Choose two.)

A.

{ for o in var.list : o => o.id }

B.

var.list[*].id

C.

[ var.list[*].id ]

D.

[ for o in var.list : o.id ]

Question 7
Single choice

Which of these options is the most secure place to store secrets foe connecting to a Terraform remote backend?

A.

Defined in Environment variables

B.

Inside the backend block within the Terraform configuration

C.

Defined in a connection configuration outside of Terraform

D.

None of above

Question 8
Single choice

Which argument(s) is (are) required when declaring a Terraform variable?

A.

type

B.

default

C.

description

D.

All of the above

E.

None of the above

Question 9
Single choice

If writing Terraform code that adheres to the Terraform style conventions, how would you properly indent each nesting level compared to the one above it?

A.

With four spaces

B.

With a tab

C.

With three spaces

D.

With two spaces

Question 10
Single choice

Terraform can import modules from a number of sources ?
which of the following is not a valid source?

A.

FTP server

B.

GitHub repository

C.

Local path

D.

Terraform Module Registry

Showing 10 of 547 questions · Unlock the full set