Summer Sale Limited Time 70% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: 70track

Free HashiCorp Terraform-Associate-004 Practice Exam with Questions & Answers | Set: 6

Questions 51

All standard backend types support state locking, and remote operations like plan, apply, and destroy.

Options:
A.

True

B.

False

HashiCorp Terraform-Associate-004 Premium Access
Questions 52

Exhibit:

resource " aws_instance " " example " {

ami = " ami-0a123456789abcdef "

instance_type = " t3.micro "

}

You are updating a child module with the resource block shown in the exhibit. The public_ip attribute of the resource needs to be accessible to the parent module. How do you meet this requirement?

Options:
A.

Create an output in the child module.

B.

Add a data source to the parent module.

C.

Add an import block to the parent module.

D.

Create a local value in the child module.

Questions 53

You are working on some new application features and you want to spin up a copy of your production deployment to perform some quick tests. In order to avoid having to configure a new state backend, what open source Terraform feature would allow you create multiple states but still be associated with your current code?

Options:
A.

Terraform data sources

B.

Terraform local values

C.

Terraform modules

D.

Terraform workspaces

E.

None of the above

Questions 54

Which of the following methods, used to provision resources into a public cloud, demonstrates the concept of infrastructure as code?

Options:
A.

curl commands manually run from a terminal

B.

A sequence of REST requests you pass to a public cloud API endpoint Most Voted

C.

A script that contains a series of public cloud CLI commands

D.

A series of commands you enter into a public cloud console

Questions 55

Exhibit:

Error: Saved plan is stale

The given plan file can no longer be applied because the state was changed by another operation after the plan was created.

You have a saved execution plan containing desired changes for infrastructure managed by Terraform. After running terraform apply my.tfplan, you receive the error shown. How can you apply the desired changes? (Pick the 2 correct responses below.)

Options:
A.

Generate a new execution plan file with terraform plan, and apply the new plan.

B.

Run terraform apply without the saved execution plan.

C.

Force the apply command by adding the flag -lock=false.

D.

Refresh the current state data using the -refresh-only flag.

E.

Update the current plan file using the terraform state push command.

Questions 56

Which of these workflows is only enabled by the use of Infrastructure as Code?

Options:
A.

Automatic scaling of resources based on application load.

B.

Role-based access control of cloud resources.

C.

Cost optimization of infrastructure deployment.

D.

Reviewing the proposed changes for potential security issues.

Questions 57

A Terraform backend determines how Terraform loads state and stores updates when you execute which command?

Options:
A.

apply

B.

destroy

C.

Both of these are correct.

D.

Neither of these are correct.

Questions 58

Your root module contains a variable namednum_servers. Which is the correct way to pass its value to a child module with an input namedservers?

Options:
A.

servers = num_servers

B.

servers = var(num_servers)

C.

servers = var.num_servers

D.

servers = ${var.num_servers}

Questions 59

Which of these ate features of Terraform Cloud? Choose two correct answers.

Options:
A.

Automated infrastructure deployment visualization

B.

Automatic backups

C.

A web-based user interface (Ul)

D.

Remote state storage

Questions 60

Which command add existing resources into Terraform state?

Options:
A.

Terraform init

B.

Terraform plan

C.

Terraform refresh

D.

Terraform import

E.

All of these