You ate making changes to existing Terraform code to add some new infrastructure. When is the best time to run terraform validate?
You want to use API tokens and other secrets within your team ' s Terraform workspaces. Where does HashiCorp recommend you store these sensitive values? (Pick the 3 correct responses)
What command can you run to generateDOT (Graphviz)formatted data to visualize Terraform dependencies?
What is modified when executing Terraform inrefresh-only mode?
terraform init retrieves and caches the configuration for all remote modules.
Which of these ate features of Terraform Cloud? Choose two correct answers.
What is the Terraform style convention for indenting a nesting level compared to the one above it?
What is the Terraform style convention for indenting a nesting level compared to the one above it?
Which task does terraform init not perform?
What does the default " local " Terraform backend store?
You can develop a custom provider to manage its resources using Terraform.
You add a new provider to your configuration and immediately run terraform apply in the CD using the local backend. Why does the apply fail?
When using multiple configuration of the same Terraform provider, what meta-argument must you include in any non-default provider configurations?
What information does the public Terraform Module Registry automatically expose about published modules?
The Terraform binary version and provider versions must match each other in a single configuration.
HashiCorp Configuration Language (HCL) supports user-denned functions.
Terraform configuration can only call modules from the public registry.
Before you can use a remote backend, you must first execute terra-form init.
Terraform providers are part of the Terraform core binary.
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?
You ' re writing a Terraform configuration that needs to read input from a local file called id_rsa.pub . Which built-in Terraform function can you use to import the file ' s contents as a string?
Which of the following command would be use to access all of the attributes and details of a resource managed by Terraform?
When should you use the force-unlock command?
Terraform providers are always installed from the Internet.
What is terraform plan -refresh-only intended to detect?
Which argument can you set on a module block to prevent Terraform from updating the module’s configuration during an init or get operation?
Why would you use the -replace flag for terraform apply?
Your team adopts AWS CloudFormation as the standardized method for provisioning public cloud resources. Which scenario presents a challenge for your team?
Which backend does the Terraform CLI use by default?
When you initialize Terraform, where does it cache modules from the public Terraform Registry?
You have developed a new cloud-based service that uses proprietary APIs and want to use Terraform to create, manage, and delete users from the service. How can Terraform interact with the service?
Which of the following can you do with terraform plan? (Pick 2 correct responses)
You corrected a typo in a resource name, changing it from aws_s3_bucket.photoes to aws_s3_bucket.photos. You want to update the Terraform state so that the existing resource is recognized under the new name, without destroying and recreating it. Which configuration should you use?
Which of the following locations can Terraform use as aprivate sourcefor modules?(Pick 2 correct responses)
You want to define a single input variable to capture configuration values for a server. The values must represent memory as a number, and the server name as a string.
Which variable type could you use for this input?
A Terraform output that sets the " sensitive " argument to true will not store that value in the state file.
Where does HashiCorp recommend you store API tokens and other secrets within your team’s Terraform workspaces?
Pick the three correct responses below.
Changing the Terraform backend from the default " local " backend to a different one after performing your first terrafom apply is:
Which command add existing resources into Terraform state?
Which Terraform collection type should you use to store key/value pairs?
What does Terraform use the .terraform.lock.hc1 file for?
You ate creating a Terraform configuration which needs to make use of multiple providers, one for AWS and one for Datadog. Which of the following provider blocks would allow you to do this?
A)

B)
C)
D)
You have just developed a new Terraform configuration for two virtual machines with a cloud provider. You would like to create the infrastructure for the first time.
Which Terraform command should you runfirst?
Which configuration consistency errors does terraform validate report?
You want to use API tokens and other secrets within your team ' s Terraform workspaces. Where does HashiCorp recommend you store these sensitive values? (Pick 3)
Exhibit:
module " network " {
source = " terraform-google-modules/network/google "
version = " ~ > 11.0 "
}
What version of the source module does Terraform allow with the module block shown in the exhibit?
Module version is required to reference a module on the Terraform Module Registry.
Running terraform fmt without any flags in a directory with Terraform configuration files will check the formatting of those files, but will never change their contents.
You’ve updated your Terraform configuration, and you need to preview the proposed changes to your infrastructure. Which command should you run?
You want to bring an existing database under Terraform management. What information is required to create a new import block for the database?
Pick the two correct responses below.
You are creating a reusable Terraform configuration and want to include an optional billing_dept tag so your Finance team can track team-specific spending on resources. Which of the following billing_dept variable declarations will achieve this?
The HCP Terraform private registry keeps the module configurations confidential within your organization.
What is an advantage of immutable infrastructure?
The -refresh-only parameter will update your state file when used with terraform plan.
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?
You want to know from which paths Terraform is loading providers referenced in your Terraform configuration (* files). You need to enable additional logging messages to find this out. Which of the following would achieve this?
You have to initialize a Terraform backend before it can be configured.
You need to destroy all of the resources in your Terraform workspace, except for aws_instance.ubuntu[1], which you want to keep. How can you tell Terraform to stop managing that specific resource without destroying it?
When you include a module block in your configuration that references a module from the Terraform Registry, the " version " attribute is required.
Terraform variable names are saved in the state file.
What is the purpose of state locking in a remote backend?
Which of the following should you add in the required_providers block to define a provider version constraint?
Which are forbidden actions when the terraform state file is locked? Choose three correct answers.
A Terraform provider is NOT responsible for:
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?
What feature stops multiple users from operating on the Terraform state at the same time?
What is the purpose of the terraform.lock.hcl file in Terraform?
Terraform configuration can only import modules from the public registry.
The public Terraform Module Registry is free to use.
What is a Terraform provider not responsible for?
Which type of block fetches or computes information for use elsewhere in a Terraform configuration?
You modified your Terraform configuration to fix a typo in the resource ID by renaming it from photoes to photos. What configuration will you add to update the resource ID in state without destroying the existing resource?
Original configuration:
resource " aws_s3_bucket " " photoes " {
bucket_prefix = " images "
}
Updated configuration:
resource " aws_s3_bucket " " photos " {
bucket_prefix = " images "
}
What kind of configuration block will create an infrastructure object with settings specified within the block?
Before you can use a new backend or HCP Terraform/Terraform Cloud integration, you must first execute terraform init.
Running terraform fmt without any flags in a directory with Terraform configuration files check the formatting of those files without changing their contents.
Where in your Terraform configuration do you specify a state backend?
A resource block is shown in the Exhibit space of this page. What is the Terraform resource name of the resource block?
You have multiple team members collaborating on infrastructure as code (IaC) using Terraform, and want to apply formatting standards for readability.
How can you format Terraform HCL (HashiCorp Configuration Language) code according to standard Terraform style convention?
One remote backend configuration always maps to a single remote workspace.
If you don’t use the local Terraform backend, where else can Terraform save resource state?
What does terraform destroy do?
Terraform configuration (including any module references) can contain only one Terraform provider type.
You have used Terraform lo create an ephemeral development environment in the (loud and are now ready to destroy all the Infrastructure described by your Terraform configuration To be safe, you would like to first see all the infrastructure that Terraform will delete.
Which command should you use to show all of the resources that mil be deleted? Choose two correct answers.
Which of these ate secure options for storing secrets for connecting to a Terraform remote backend? Choose two correct answers.
What type of block is used to construct a collection of nested configuration blocks?
You are using a networking module in your Terraform configuration with the name label my-network. In your main configuration you have the following code:
When you run terraform validate, you get the following error:
What must you do to successfully retrieve this value from your networking module?
The terraform output command shows outputs from child modules.
Terraformrequiresthe Go runtime as a prerequisite for installation.
Which of the following should you add in the required_providers block to define a provider version constraint?
Which parameters does terraform import require? Choose two correct answers.
You can access state stored with the local backend by using terraform_remote_state data source.
A Terraform backend determines how Terraform loads state and stores updates when you execute which command?
Infrastructure as Code (laC) can be stored in a version control system along with application code.
Exhibit:
resource " kubernetes_namespace " " example " {
name = " test "
}
A resource block is shown in the exhibit. How would you reference the name attribute of this resource in HCL?
A resource block is shown in the Exhibit section of this page. How would you reference the attribute name of this resource in HCL?