What Terraform command always causes a state file to be updated with changes that might have been made outside of Terraform?
You want to define multiple data disks as nested blocks inside the resource block for a virtual machine. What Terraform feature would help you define the blocks using the values in a variable?
Which of these statements about HCP Terraform/Terraform Cloud workspaces is false?
When you run terraform apply, the Terraform CLI will print output values from both the root module and any child modules.
Which of the following can you do with terraform plan? (Pick 2 correct responses)
What kind of configuration block will create an infrastructure object with settings specified within the block?
Once you configure a new Terraform backend with a terraform code block, which command(s) should you use to migrate the state file?
What is the Terraform style convention for indenting a nesting level compared to the one above it?
You just upgraded the version of a provider in an existing Terraform project. What do you need to do to install the new provider?
Which of these are benefits of using Sentinel with HCP Terraform/Terraform Cloud? (Pick the 3 correct responses)
Setting the TF_LOG environment variable to DEBUG causes debug messages to be logged into stdout.
Terraform variables and outputs that set the description argument will store that description in the state file.
Which of the following isnotan advantage of using Infrastructure as Code (IaC) operations?
Which provider authentication method prevents credentials from being stored in the state file?
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 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?
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?
How can you trigger a run in a Terraform Cloud workspace that is connected to a Version Control System (VCS) repository?
Which of the following ate advantages of using infrastructure as code (laC) instead of provisioning with a graphical user interface (GUI)? Choose two correct answers.
How do you specify a module’s version when publishing it to the public terraform Module Registry?
Which of the following does terraform apply change after you approve the execution plan? (Choose two.)
Your security team scanned some Terraform workspaces and found secrets stored in plaintext in state files. How can you protect that data?
Which of the following is true about terraform apply?(Pick 2 correct responses)
All standard backend types support state locking, and remote operations like plan, apply, and destroy.
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?
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.
If a DevOps team adopts AWS CloudFormation as their standardized method for provisioning public cloud resoruces, which of the following scenarios poses a challenge for this team?
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 can reference a resource created with for_each using a Splat ( *) expression.
What does Terraform not reference when running a terraform apply -refresh-only ?
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 must use different Terraform commands depending on the cloud provider you use.
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?
Which of these are features of HCP Terraform/Terraform Cloud? (Pick the 2 correct responses)
Which of these actions will prevent two Terraform runs from changing the same state file at the same time?
In Terraform HCL, an object type of object({name=string, age-number}) would match this value.
Your DevOps team is currently using the local backend for your Terraform configuration. You would like to move to a remote backend to store the state file in a central location. Which of the following backends would not work?
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?
As a developer, you want to ensure your plugins are up to date with the latest versions. Which Terraform command should you use?
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
terraform validate confirms that your infrastructure matches the Terraform state file.
Which of the following arguments are required when declaring a Terraform output?
You should run terraform fnt to rewrite all Terraform configurations within the current working directory to conform to Terraform-style conventions.