Once you configure a new Terraform backend with a terraform code block, which command(s) should you use to migrate the state file?
Your risk management organization requires that new AWS S3 buckets must be private and encrypted at rest. How can Terraform Cloud automatically and proactively enforce this security control?
Which of these actions will prevent two Terraform runs from changing the same state file at the same time?
Multiple team members are collaborating on infrastructure using Terraform and want to format the* Terraform code following standard Terraform-style convention.
How should they ensure the code satisfies conventions?
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?
When using multiple configuration of the same Terraform provider, what meta-argument must you include in any non-default provider configurations?
Which of the following command would be use to access all of the attributes and details of a resource managed by Terraform?
Which of the following commands would you use to access all of the attributes and details of a resource managed by Terraform?
What is the provider for the resource shown in the Exhibit?
resource "aws_vpc" "main" {
name = "test"
}
What is the Terraform style convention for indenting a nesting level compared to the one above it?
It is best practice to store secret data in the same version control repository as your Terraform configuration.
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?
Which method for sharing Terraform configurations fulfills the following criteria:
1. Keeps the configurations confidential within your organization
2. Support Terraform’s semantic version constrains
3. Provides a browsable directory
Running terraform fmt without any flags in a directory with Terraform configuration files check the formatting of those files without changing their contents.
In Terraform HCL, an object type of object({name=string, age-number}) would match this value.
Which type of block fetches or computes information for use elsewhere in a Terraform configuration?
When you include a module block in your configuration that references a module from the Terraform Registry, the "version" attribute is required.
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?
How do you specify a module’s version when publishing it to the public terraform Module 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?
What command can you run to generateDOT (Graphviz)formatted data to visualize Terraform dependencies?
You have a Terraform configuration that defines a single virtual machine with no references to it, You have run terraform apply to create the resource, and then removed the resource definition from your Terraform configuration file.
What will happen you run terraform apply in the working directory again?
Which of these are features of HCP Terraform/Terraform Cloud? Pick the 2 correct responses below.
What feature stops multiple users from operating on the Terraform state at the same time?
How can you trigger a run in a Terraform Cloud workspace that is connected to a Version Control System (VCS) repository?
Which two steps are required to provision new infrastructure in the Terraform workflow? Choose two correct answers.
Terraform variables and outputs that set the description argument will store that description in the state file.
You must use different Terraform commands depending on the cloud provider you use.
You modified your Terraform configuration and run Terraform plan to review the changes. Simultaneously, your teammate manually modified the infrastructure component you are working on. Since you already ran terraform plan locally, the execution plan for terraform apply will be the same.
Which of the following is true about terraform apply?(Pick 2 correct responses)
You can reference a resource created with for_each using a Splat ( *) expression.
While attempting to deploy resources into your cloud provider using Terraform, you begin to see some odd behavior and experience slow responses. In order to troubleshoot you decide to turn on Terraform debugging. Which environment variables must be configured to make Terraform's logging more verbose?
A module block is shown in the Exhibit space of this page. When you use a module block to reference a module from the Terraform Registry such as the one in the example, how do you specify version 1.0.0 of the module?
You add a new resource to an existing Terraform configuration, but do not update the version constraint in the configuration. The existing and new resources use the same provider. The working contains a .terraform.lock, hc1 file.
How will Terraform choose which version of the provider to use?
Which of the following methods, used to provision resources into a public cloud, demonstrates the concept of infrastructure as code?
When you initialize Terraform, where does it cache modules from the public Terraform Registry?
You just upgraded the version of a provider in an existing Terraform project. What do you need to do to install the new provider?
You used Terraform to create an ephemeral development environment in the cloud 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 the resources that will be deleted? (Pick the 2 correct responses)