- (Exam Topic 4)
In the example below, the depends_on argument creates what type of dependency?
Correct Answer:C
- (Exam Topic 4)
Given the below resource configuration - resource "aws_instance" "web" { # ... count = 4 }
What does the terraform resource address aws_instance.web refer to?
Correct Answer:A
A Resource Address is a string that references a specific resource in a larger infrastructure. An address is made up of two parts:
[module path][resource spec] Module path:
A module path addresses a module within the tree of modules. It takes the form: module.A.module.B.module.C...
Multiple modules in a path indicate nesting. If a module path is specified without a resource spec, the address applies to every resource within the module. If the module path is omitted, this addresses the root module.
Given a Terraform config that includes: resource "aws_instance" "web" {
# ...
count = 4
}
An address like this: aws_instance.web[3]
Refers to only the last instance in the config, and an address like this: aws_instance.web
Refers to all four "web" instances. https://www.terraform.io/docs/internals/resource-addressing.html
- (Exam Topic 4)
What command can you run to generate DOT (Document Template) formatted data to visualize Terraform dependencies?
Correct Answer:C
The terraform graph command is used to generate a visual representation of either a configuration or execution plan. The output is in the DOT format, which can be used by GraphViz to generate charts.
- (Exam Topic 2)
Please identify the offerings which are unique to Terraform Enterprise, and not available in either Terraform OSS, or Terraform Cloud. Select four.
Correct Answer:ABE
https://www.hashicorp.com/products/terraform/pricing/
- (Exam Topic 3)
You cannot publish your own modules on the Terraform Registry.
Correct Answer:A
Anyone can publish and share modules on the Terraform Registry. https://www.terraform.io/docs/registry/modules/publish.html
- (Exam Topic 3)
Which of the following allows Terraform users to apply policy as code to enforce standardized configurations for resources being deployed via infrastructure as code?
Correct Answer:A
Sentinel is a language and framework for policy built to be embedded in existing software to enable
fine-grained, logic-based policy decisions. A policy describes under what circumstances certain behaviors are allowed. Sentinel is an enterprise-only feature.
https://www.youtube.com/watch?v=Vy8s7AAvU6g&feature=emb_title