Free Terraform Associate Exam Braindumps (page: 59)

Page 59 of 113

From the answers below, select the advantages of using Infrastructure as Code.

  1. Provide a codified workflow to develop customer-facing applications.
  2. Safely test modifications using a "dry run" before applying any actual changes.
  3. Easily integrate with application workflows (GitLab Actions, Azure DevOps, CI/CD tools).
  4. Easily change and update existing infrastructure.
  5. Provide reusable modules for easy sharing and collaboration.

Answer(s): B,C,D,E

Explanation:

Infrastructure as Code is not used to develop applications, but it can be used to help deploy or provision those applications to a public cloud provider or on-premises infrastructure.
All of the others are benefits to using Infrastructure as Code over the traditional way of managing infrastructure, regardless if it's public cloud or on-premises.



What resource dependency information is stored in Terraform's state?

  1. Only implicit dependencies are stored in state.
  2. Both implicit and explicit dependencies are stored in state.
  3. Only explicit dependencies are stored in state.
  4. No dependency information is stored in state.

Answer(s): B

Explanation:

Terraform state captures all dependency information, both implicit and explicit. One purpose for state is to determine the proper order to destroy resources. When resources are created all of their dependency information is stored in the state. If you destroy a resource with dependencies, Terraform can still determine the correct destroy order for all other resources because the dependencies are stored in the state.


Reference:

https://www.terraform.io/docs/state/purpose.html#metadata



Consider the following Terraform 0.12 configuration snippet:
1. variable "vpc_cidrs" {
2. type = map
3. default = {
4. us-east-1 = "10.0.0.0/16"
5. us-east-2 = "10.1.0.0/16"
6. us-west-1 = "10.2.0.0/16"
7. us-west-2 = "10.3.0.0/16"
8. }
9. }
10.
11. resource "aws_vpc" "shared" {
12. cidr_block =
13. }
How would you define the cidr_block for us-east-1 in the aws_vpc resource using a variable?

  1. var.vpc_cidrs.0
  2. vpc_cidrs[“us-east-1”]
  3. var.vpc_cidrs[“us-east-1”]
  4. var.vpc_cidrs[0]

Answer(s): C



Your organization has moved to AWS and has manually deployed infrastructure using the console. Recently, a decision has been made to standardize on Terraform for all deployments moving forward. What can you do to ensure that all existing is managed by Terraform moving forward without interruption to existing services?

  1. Submit a ticket to AWS and ask them to export the state of all existing resources and use terraform import to import them into the state file.
  2. Delete the existing resources and recreate them using new a Terraform configuration so Terraform can manage them moving forward.
  3. Resources that are manually deployed in the AWS console cannot be imported by Terraform.
  4. Using terraform import, import the existing infrastructure into your Terraform state.

Answer(s): D

Explanation:

Terraform is able to import existing infrastructure. This allows us take resources we've created by some other means (i.e. via console) and bring it under Terraform management.
This is a great way to slowly transition infrastructure to Terraform.
The terraform import command is used to import existing infrastructure.
To import a resource, first write a resource block for it in our configuration, establishing the name by which it will be known to Terraform.
Example:
resource "aws_instance" "import_example" {

# ...instance configuration...
}
Now terraform import can be run to attach an existing instance to this resource configuration.
$ terraform import aws_instance.import_example i-03efafa258104165f aws_instance.import_example: Importing from ID "i-03efafa258104165f"... aws_instance.import_example: Import complete!
Imported aws_instance (ID: i-03efafa258104165f) aws_instance.import_example: Refreshing state... (ID: i-03efafa258104165f) Import successful!
The resources that were imported are shown above. These resources are now in your Terraform state and will henceforth be managed by Terraform.
This command locates the AWS instance with ID i-03efafa258104165f (which has been created outside Terraform) and attaches its existing settings, as described by the EC2 API, to the name aws_instance.import_example in the Terraform state.



Page 59 of 113



Post your Comments and Discuss HashiCorp Terraform Associate exam with other Community members:

Bin Mahamood commented on November 03, 2024
terraform { required_providers { aws = { version = ">= 2.7.0" source = "hashicorp/aws" } } }
Anonymous
upvote

Nayaran commented on October 21, 2024
First and for most... this exam is extremely hard. Second this exam dump contains majority of the questions. I passed the certification exam.
UNITED STATES
upvote

Marc commented on October 21, 2024
hello would need help
UNITED STATES
upvote

Marcellus Werifah commented on October 20, 2024
Verified answers
UNITED STATES
upvote

Nathan commented on October 20, 2024
Using dumps are my last resort. And that is what I ended up using with this exam to pass. The exam is extremely difficult.
France
upvote

Marcellus Werifah commented on October 20, 2024
Who decides what is the correct in case of conflicts
UNITED STATES
upvote

Marcellus Werifah commented on October 20, 2024
Novice. Would need detailed explanation of any questions
UNITED STATES
upvote

Siva commented on June 17, 2024
It's a good platform to start preparing for the HCTA 003 exam
Anonymous
upvote

Dhiraj Bhattad commented on June 14, 2024
It's a good platform to start preparing for the HCTA 003 exam.
Anonymous
upvote

Amizhchandra commented on May 12, 2024
Good material
CHINA
upvote

Direen commented on February 16, 2024
This was a easy passsss! Scored 95%. Unbelievable! I was hesitant at first but then I saw the pass guarantee policy so I said what the hell. If I fa I will get my money back. I am glad I bought it. Saved me so much time.
United States
upvote

Satya commented on February 09, 2024
Q83:--Terraform can only manage resource dependencies if you set them explicitly with the depends_on argument. Answer is "False"
UNITED STATES
upvote

Satya commented on February 09, 2024
Q76:---Which of these options is the most secure place to store secrets foe connecting to a Terraform remote backend? Shouldn't the answer be "Defined in a connection configuration outside of Terraform"
UNITED STATES
upvote

Satya commented on February 09, 2024
Q39:---Which argument(s) is (are) required when declaring a Terraform variable? Answer should be "None of the above" as Nothing is required while declaring variable
UNITED STATES
upvote

DN commented on September 04, 2023
question 14 - run terraform import: this is the recommended best practice for bringing manually created or destroyed resources under terraform management. you use terraform import to associate an existing resource with a terraform resource configuration. this ensures that terraform is aware of the resource, and you can subsequently manage it with terraform.
Anonymous
upvote

YK commented on December 11, 2023
good one nice
JAPAN
upvote

Mn8300 commented on November 09, 2023
nice questions
Anonymous
upvote

Naka commented on January 19, 2024
Very good, many questions same as the real exam
BRAZIL
upvote

vasu commented on December 22, 2023
good for practice
INDIA
upvote

MDN commented on December 11, 2023
Good sample questions
UNITED STATES
upvote

YK commented on December 11, 2023
Good one nice
JAPAN
upvote

YK 11 commented on December 09, 2023
Good one nice
JAPAN
upvote

Mn8300 commented on November 13, 2023
Very useful
Anonymous
upvote

Mn8300 commented on November 09, 2023
Nice questions
Anonymous
upvote

mpakal commented on October 19, 2023
Good and realistic questions.
UNITED STATES
upvote

pakalamb1995@gmail.com commented on October 19, 2023
so far nice
UNITED STATES
upvote

CP commented on October 09, 2023
Let Hope for the Best
EUROPEAN UNION
upvote

DN commented on September 04, 2023
Question 14 - Run terraform import: This is the recommended best practice for bringing manually created or destroyed resources under Terraform management. You use terraform import to associate an existing resource with a Terraform resource configuration. This ensures that Terraform is aware of the resource, and you can subsequently manage it with Terraform.
Anonymous
upvote

sipho commented on August 30, 2023
i will study ans see how it goes
Anonymous
upvote

Jersey boy commented on June 25, 2023
I just paid and download my files. I will report in a week after writing my exam to see how this goes.
UNITED STATES
upvote

Yung K. commented on October 11, 2021
Thank you for this exams dumps package. From the 2 exams I purchased as part of the 50% sale I alredy passed first exam.
TAIWAN
upvote