Terraform 20221025
Terraform 20221025
A. True
B. False
Correct Answer: B
Reference:
https://www.terraform.io/docs/language/state/index.html
A. True
B. False
Correct Answer: A
Reference:
https://www.terraform.io/docs/language/settings/backends/remote.html
To use a single remote Terraform Cloud workspace, set workspaces.name to the remote workspace's full name (like networking-prod).
To use multiple remote workspaces, set workspaces.prefix to a prefix used in all of the desired remote workspace names. For example, set prefix =
"networking-" to use Terraform cloud workspaces with names like networking-dev and networking-prod. This is helpful when mapping multiple
Terraform CLI workspaces used in a single Terraform configuration to multiple Terraform Cloud workspaces.
upvoted 2 times
Certain backends support multiple named workspaces, allowing multiple states to be associated with a single configuration. The configuration still
has only one backend, but multiple distinct instances of that configuration to be deployed without configuring a new backend or changing
authentication credentials.
Named workspaces allow conveniently switching between multiple instances of a single configuration within its single backend. They are
convenient in a number of situations, but cannot solve all problems.
Named workspaces allow conveniently switching between multiple instances of a single configuration within its single backend. They are
convenient in a number of situations, but cannot solve all problems."
https://www.terraform.io/language/state/workspaces
upvoted 3 times
Zam88 4 months, 1 week ago
The remote backend can work with either a single remote Terraform Cloud workspace, or with multiple similarly-named remote workspaces (like
networking-dev and networking-prod). The workspaces block of the backend configuration determines which mode it uses:
Correct B
upvoted 3 times
How is the Terraform remote backend different than other state backends such as S3, Consul, etc.?
Correct Answer: A
If you and your team are using Terraform to manage meaningful infrastructure, we recommend using the remote backend with Terraform Cloud
or Terraform
Enterprise.
Reference:
https://www.terraform.io/docs/language/settings/backends/index.html
A given Terraform configuration can either specify a backend, integrate with Terraform Cloud, or do neither and default to storing state locally.
correct A
upvoted 2 times
A. terraform plan to import the current infrastructure to the state �le, make code changes, and terraform apply to update the infrastructure.
B. Write a Terraform con�guration, run terraform show to view proposed changes, and terraform apply to create new infrastructure.
C. terraform import to import the current infrastructure to the state �le, make code changes, and terraform apply to update the infrastructure.
D. Write a Terraform con�guration, run terraform init, run terraform plan to view planned infrastructure changes, and terraform apply to create
new infrastructure.
Correct Answer: D
A. True
B. False
Correct Answer: A
Reference:
https://github.com/hashicorp/terraform/issues/17928
Unlike many other objects in the Terraform language, a provider block may be omitted if its contents would otherwise be empty. Terraform
assumes an empty default configuration for any provider that is not explicitly configured.
https://www.terraform.io/language/providers/configuration
upvoted 11 times
You run a local-exec provisioner in a null resource called null_resource.run_script and realize that you need to rerun the script.
Which of the following commands would you use �rst?
Correct Answer: A
Terraform does not keep track of what the provisioners do. So if we run a script via local-exec, terraform has no idea what the script does, nor can it
track it's changes. That is the exact reason why terraform says that provisioners are the last resort.
Running taint (A), would not delete the resources created via the script, but it would mark the null_resource.script for deletion and wait for the next
run.
A. remote-exec
B. null-exec
C. local-exec
D. �le
Correct Answer: A
The remote-exec provisioner invokes a script on a remote resource after it is created.
Reference:
https://www.terraform.io/docs/language/resources/provisioners/remote-exec.html
"The local-exec provisioner invokes a local executable after a resource is created. This invokes a process on the machine running Terraform, not on
the resource." https://www.terraform.io/language/resources/provisioners/local-exec
remote-exec correct
upvoted 1 times
D. Major cloud vendors and non-cloud vendors can write, maintain, or collaborate on Terraform providers
Correct Answer: D
Reference:
https://jayendrapatil.com/terraform-cheat-sheet/#Terraform_Read_and_write_con�guration
https://www.terraform.io/language/providers
upvoted 2 times
What command does Terraform require the �rst time you run it within a con�guration directory?
A. terraform import
B. terraform init
C. terraform plan
D. terraform workspace
Correct Answer: B
terraform init command is used to initialize a working directory containing Terraform con�guration �les.
Reference:
https://www.terraform.io/docs/cli/commands/init.html
You have deployed a new webapp with a public IP address on a cloud provider. However, you did not create any outputs for your code.
What is the best method to quickly �nd the IP address of the resource you deployed?
B. In a new folder, use the terraform_remote_state data source to load in the state �le, then write an output for each resource that you �nd the
state �le
C. Run terraform state list to �nd the name of the resource, then terraform state show to �nd the attributes including public IP address
D. Run terraform destroy then terraform apply and look for the IP address in stdout
Correct Answer: A
Reference:
https://www.terraform.io/docs/cli/commands/output.html
A. Versioned infrastructure
B. Golden images
C. Idempotence
D. Self-describing infrastructure
Terraform variables and outputs that set the "description" argument will store that description in the state �le.
A. True
B. False
Correct Answer: A
A. vpc
B. main
C. aws
D. test
Correct Answer: C
Reference:
https://docs.aws.amazon.com/cloudformation-cli/latest/userguide/resource-types.html
If you manually destroy infrastructure, what is the best practice re�ecting this change in Terraform?
Correct Answer: B
https://www.terraform.io/cli/commands
/refresh#:~:text=The%20terraform%20refresh%20command%20reads%20the%20current%20settings%20from%20all%20managed%20remote%20
objects%20and%20updates%20the%20Terraform%20state%20to%20match
upvoted 2 times
"The terraform refresh command reads the current settings from all managed remote objects and updates the Terraform state to match.
Warning: This command is deprecated, because its default behavior is unsafe if you have misconfigured credentials for any of your providers. See
below for more information and recommended alternatives.
This won't modify your real remote objects, but it will modify the Terraform state.
You shouldn't typically need to use this command, because Terraform automatically performs the same refreshing actions as a part of creating a
plan in both the terraform plan and terraform apply commands. This command is here primarily for backward compatibility, but we don't
recommend using it because it provides no opportunity to review the effects of the operation before updating the state."
https://www.terraform.io/cli/commands/refresh
upvoted 1 times
A. State �le
B. Con�guration �le
C. Credentials
D. Cloud provider
Correct Answer: CD
Reference:
https://www.terraform.io/docs/cli/commands/refresh.html
What information does the public Terraform Module Registry automatically expose about published modules?
C. Outputs
Correct Answer: E
Reference:
https://www.terraform.io/docs/registry/modules/publish.html
If a module uses a local values, you can expose that value with a terraform output.
A. True
B. False
Correct Answer: A
Output values are like function return values.
Reference:
https://www.terraform.io/docs/language/values/locals.html
https://www.terraform.io/docs/language/values/outputs.html
You should store secret data in the same version control repository as your Terraform con�guration.
A. True
B. False
Correct Answer: B
Reference:
https://blog.gruntwork.io/a-comprehensive-guide-to-managing-secrets-in-your-terraform-code-1d586955ace1
A. split
B. join
C. slice
D. chomp
Correct Answer: D
Reference:
https://www.terraform.io/docs/language/functions/chomp.html
https://www.terraform.io/language/functions
upvoted 14 times
You have provisioned some virtual machines (VMs) on Google Cloud Platform (GCP) using the gcloud command line tool. However, you are
standardizing with
Terraform and want to manage these VMs using Terraform instead.
What are the two things you must do to achieve this? (Choose two.)
Correct Answer: BD
The terraform import command is used to import existing infrastructure.
Import existing Google Cloud resources into Terraform with Terraformer.
Reference:
https://www.terraform.io/docs/cli/import/usage.html
https://cloud.google.com/docs/terraform
You have recently started a new job at a retailer as an engineer. As part of this new role, you have been tasked with evaluating multiple outages
that occurred during peak shopping time during the holiday season. Your investigation found that the team is manually deploying new compute
instances and con�guring each compute instance manually. This has led to inconsistent con�guration between each compute instance.
How would you solve this using infrastructure as code?
A. Implement a ticketing work�ow that makes engineers submit a ticket before manually provisioning and con�guring a resource
B. Implement a checklist that engineers can follow when con�guring compute instances
C. Replace the compute instance type with a larger version to reduce the number of required deployments
D. Implement a provisioning pipeline that deploys infrastructure con�gurations committed to your version control system following code
reviews
Correct Answer: A
A. True
B. False
Correct Answer: A
Which two steps are required to provision new infrastructure in the Terraform work�ow? (Choose two.)
A. Destroy
B. Apply
C. Import
D. Init
E. Validate
Correct Answer: BD
Reference:
https://www.terraform.io/guides/core-work�ow.html
A. When you want to force Terraform to destroy a resource on the next apply
B. When you want to force Terraform to destroy and recreate a resource on the next apply
D. When you want Terraform to destroy all the infrastructure in your workspace
Correct Answer: B
The terraform taint command manually marks a Terraform-managed resource as tainted, forcing it to be destroyed and recreated on the next
apply.
Reference:
https://www.terraform.io/docs/cli/commands/taint.html
"The terraform taint command informs Terraform that a particular object has become degraded or damaged. Terraform represents this by marking
the object as "tainted" in the Terraform state, and Terraform will propose to replace it in the next plan you create."
https://www.terraform.io/cli/commands/taint
upvoted 4 times
A. True
B. False
Correct Answer: B
Reference:
https://www.terraform.io/docs/extend/guides/v1-upgrade-guide.html
A. You see a status message that you cannot acquire the lock
Correct Answer: C
Manually unlock the state for the de�ned con�guration.
Reference:
https://www.terraform.io/docs/cli/commands/force-unlock.html
Terraform can import modules from a number of sources `" which of the following is not a valid source?
A. FTP server
B. GitHub repository
C. Local path
Correct Answer: A
Which of the following is available only in Terraform Enterprise or Cloud workspaces and not in Terraform CLI?
Correct Answer: A
A. True
B. False
Correct Answer: A
The terraform validate command validates the syntax and arguments of the Terraform con�guration �les.
Reference:
https://www.terraform.io/docs/cli/code/index.html
https://www.terraform.io/cli/commands/validate
upvoted 4 times
Question #30 Topic 1
You have used Terraform to create an ephemeral development environment in the cloud and are now ready to destroy all the infrastructure
described by your
Terraform con�guration. To be safe, you would like to �rst see all the infrastructure that will be deleted by Terraform.
Which command should you use to show all of the resources that will be deleted? (Choose two.)
B. This is not possible. You can only show resources that will be created.
D. Run terraform destroy and it will �rst output all the resources that will be deleted before prompting for approval.
Correct Answer: CD
Reference:
https://www.terraform.io/docs/cli/commands/state/rm.html
C is absurd that will make the deployed resources not managible by Terraform
upvoted 2 times
For that reason, this command accepts most of the options that terraform apply accepts, although it does not accept a plan file argument and
forces the selection of the "destroy" planning mode.
upvoted 1 times
cjig 3 months ago
Selected Answer: AD
Answer is A and D
upvoted 1 times
Which of the following is the correct way to pass the value in the variable num_servers into a module with the input servers?
A. servers = num_servers
B. servers = variable.num_servers
C. servers = var(num_servers)
D. servers = var.num_servers
Correct Answer: A
"Within the module that declared a variable, its value can be accessed from within expressions as var.<NAME>, where <NAME> matches the label
given in the declaration block:
Note: Input variables are created by a variable block, but you reference them as attributes on an object named var."
https://www.terraform.io/language/values/variables#using-input-variable-values
upvoted 3 times
A. True
B. False
Correct Answer: A
Most provisioners require access to the remote resource via SSH or WinRM, and expect a nested connection block with details about how to
connect.
Reference:
https://www.terraform.io/docs/language/resources/provisioners/connection.html
Example:
provisioner "local-exec" {
command = "echo The server's IP address is ${self.private_ip}"
}
}
upvoted 5 times
provider "aws" {
region = "us-west-1"
}
provider "aws" {
alias = "aws02"
region = "ap-south-1"
}
Looking at my lab example. The answer is false. You can put it inside resource block but it doesn't have to be. You only put it in resource block if
there are multiple providers.
upvoted 3 times
"If you are certain that provisioners are the best way to solve your problem after considering the advice in the sections above, you can add a
provisioner block inside the resource block of a compute instance."
https://www.terraform.io/language/resources/provisioners/syntax?_ga=2.158695858.964344447.1656246968-433701022.1656246968&
_gl=1*1rbcuyq*_ga*NDMzNzAxMDIyLjE2NTYyNDY5Njg.*_ga_P7S46ZYEKW*MTY1NjI3MDA3Ny4yLjEuMTY1NjI3MTM5NS4w#how-to-use-
provisioners
upvoted 2 times
Terraform can run on Windows or Linux, but it requires a Server version of the Windows operating system.
A. True
B. False
Correct Answer: B
A. tfplan �les
B. Terraform binary
C. Provider plugins
D. State �le
Correct Answer: D
The local backend stores state on the local �lesystem, locks that state using system APIs, and performs operations locally.
Reference:
https://www.terraform.io/docs/language/settings/backends/local.html
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 Con�guration Language) code according to standard Terraform style convention?
A. Run the terraform fmt command during the code linting phase of your CI/CD process
B. Designate one person in each team to review and format everyone's code
C. Manually apply two spaces indentation and align equal sign "=" characters in every Terraform �le (*.tf)
D. Write a shell script to transform Terraform �les using tools such as AWK, Python, and sed
Correct Answer: C
✑ Indent two spaces for each nesting level.
✑ When multiple arguments with single-line values appear on consecutive lines at the same nesting level, align their equals signs.
Reference:
https://www.terraform.io/docs/language/syntax/style.html
What value does the Terraform Cloud/Terraform Enterprise private module registry provide over the public Terraform Module Registry?
A. The ability to share modules with public Terraform users and members of Terraform Enterprise Organizations
Correct Answer: D
Terraform Registry is an index of modules shared publicly using this protocol. This public registry is the easiest way to get started with
Terraform and �nd modules created by others in the community.
Reference:
https://www.terraform.io/docs/language/modules/sources.html
A. Sources all providers present in the con�guration and ensures they are downloaded and available locally
Correct Answer: D
Reference:
https://www.terraform.io/docs/cli/commands/init.html
You have declared a variable called var.list which is a list of objects that all have an attribute id.
Which options will produce a list of the IDs? (Choose two.)
B. var.list[*].id
C. [ var.list[*].id ]
Correct Answer: AB
[for o in var.list : o.id] This is equivalent to the following splat expression: var.list[*].id
upvoted 1 times
https://www.terraform.io/language/expressions/splat
upvoted 1 times
A. type
B. default
C. description
Correct Answer: B
The variable declaration can also include a default argument.
Reference:
https://www.terraform.io/docs/language/values/variables.html
variable "application_name" {
}
When using a module block to reference a module stored on the public Terraform Module Registry such as:
A. Modules stored on the public Terraform Module Registry do not support versioning
D. Nothing ג€" modules stored on the public Terraform Module Registry always default to version 1.0.0
Correct Answer: C
Version
When using modules installed from a module registry, we recommend explicitly constraining the acceptable version numbers to avoid unexpected
or unwanted changes.
module "consul" {
source = "hashicorp/consul/aws"
version = "0.0.5"
servers = 3
}
upvoted 12 times
The version argument accepts a version constraint string. Terraform will use the newest installed version of the module that meets the constraint; if
no acceptable versions are installed, it will download the newest version that meets the constraint.
Version constraints are supported only for modules installed from a module registry, such as the public Terraform Registry or Terraform Cloud's
private module registry. Other module sources can provide their own versioning mechanisms within the source string itself, or might not support
versions at all. In particular, modules sourced from local file paths do not support version; since they're loaded from the same source repository,
they always share the same version as their caller.
https://www.terraform.io/language/modules/syntax#version
upvoted 2 times
What features does the hosted service Terraform Cloud provide? (Choose two.)
B. Automatic backups
Correct Answer: BC
Reference:
https://www.terraform.io/docs/enterprise/admin/automated-recovery.html https://www.terraform.io/docs/language/state/remote.html
Correct Answer: C
The local backend stores state on the local �lesystem, locks that state using system APIs, and performs operations locally.
Reference:
https://www.terraform.io/docs/language/settings/backends/local.html
https://www.terraform.io/language/settings/backends/local
upvoted 5 times
Which option can not be used to keep secrets out of Terraform con�guration �les?
A. A Terraform provider
B. Environment variables
C. A -var �ag
D. secure string
Correct Answer: C
Reference:
https://secrethub.io/blog/secret-management-for-terraform/
A. A Terraform provider - can pass strings and templates containing secrets within provider module
B. Environment variables - TF_VAR can be used to inject secrets outside of code
C. A -var flag - Can be used to pass variable from secret.tfvars file
D. secure string - Can be used to hold password
Correct answer is B
https://blog.gruntwork.io/a-comprehensive-guide-to-managing-secrets-in-your-terraform-code-1d586955ace1
upvoted 4 times
Correct Answer: A
Reference:
https://github.com/hashicorp/terraform/issues/19291
A. True
B. False
Correct Answer: B
Examine the following Terraform con�guration, which uses the data source for an AWS AMI.
What value should you enter for the ami argument in the AWS instance resource?
A. aws_ami.ubuntu
B. data.aws_ami.ubuntu
C. data.aws_ami.ubuntu.id
D. aws_ami.ubuntu.id
Correct Answer: C
resource "aws_instance" "web" {
ami = data.aws_ami.ubuntu.id
Reference:
https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/instance
https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/instance
upvoted 4 times
Question #47 Topic 1
FILL BLANK -
You need to specify a dependency manually.
What resource meta-parameter can you use to make sure Terraform respects the dependency?
Type your answer in the �eld provided. The text �eld is not case-sensitive and all variations of the correct answer are accepted.
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 con�guration 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?
A. The Terraform state �le contains all 16 VMs in the team account. Execute terraform destroy and select the newly-created VM.
B. The Terraform state �le only contains the one new VM. Execute terraform destroy.
D. Delete the VM using the cloud provider console and terraform apply to apply the changes to the Terraform state �le.
Correct Answer: B
read the question carefully "Terraform configuration containing one VM, perform terraform apply" so only one VM is in state file.
B should be correct
upvoted 2 times
HDDH 4 months ago
Selected Answer: B
For sure
upvoted 2 times
" A. The Terraform state file contains all 16 VMs in the team account. Execute terraform destroy and select the newly-created VM. " ---- what
does that meant "select the newly-created VM" you can't destroy a single resource, to destroy and recreate a new resource you use terraform
taint to mark the resource for deletions and recreation
upvoted 3 times
A. dev
B. azurerm_resource_group
C. azurerm
D. test
Correct Answer: A
Setting the TF_LOG environment variable to DEBUG causes debug messages to be logged into syslog.
A. True
B. False
Correct Answer: A
Reference:
https://www.terraform.io/docs/internals/debugging.html
https://www.terraform.io/internals/debugging
upvoted 1 times
Use TF_LOG_PATH to specify a file path where the log output file should be written. If you do not specify a log path, Terraform writes the specified
log output to stderr.
"Stderr, also known as standard error, is the default file descriptor where a process can write error messages.
In Unix-like operating systems, such as Linux, macOS X, and BSD, stderr is defined by the POSIX standard. Its default file descriptor number is 2.
https://www.computerhope.com/jargon/s/stderr.htm#:~:text=Stderr
%2C%20also%20known%20as%20standard,defaults%20to%20the%20user's%20screen.
upvoted 1 times
"Terraform has detailed logs which can be enabled by setting the TF_LOG environment variable to any value. This will cause detailed logs to appear
on stderr."
"To persist logged output you can set TF_LOG_PATH in order to force the log to always be appended to a specific file when logging is enabled.
Note that even when TF_LOG_PATH is set, TF_LOG must be set in order for any logging to be enabled."
https://www.terraform.io/internals/debugging
"Logging is off for all subsystems by default. To enable logging for a Terraform run, set one or more logging environment variables to either JSON
format or a verbosity level."
"Use TF_LOG_PATH to specify a file path where the log output file should be written. If you do not specify a log path, Terraform writes the specified
log output to stderr."
Terraform can automatically create the output file at TF_LOG_PATH if it does not already exist. If the file does exist, Terraform adds new log output
onto the end of the file without truncating the file contents."
https://www.terraform.io/plugin/log/managing#enable-logging
upvoted 2 times
https://www.computerhope.com/jargon/s/stderr.htm#:~:text=Stderr
%2C%20also%20known%20as%20standard,defaults%20to%20the%20user's%20screen.
upvoted 1 times
B
upvoted 2 times
https://www.terraform.io/internals/debugging
upvoted 3 times
pj2001 5 months ago
B, TF_LOG setting would send logs to stderr / console / terminal, not syslog
upvoted 5 times
Correct Answer: A
Backends are con�gured with a nested backend block within the top-level terraform block.
Reference:
https://www.terraform.io/docs/language/settings/backends/con�guration.html
https://www.terraform.io/language/settings/backends/configuration
https://www.terraform.io/language/settings/backends/configuration#using-a-backend-block
upvoted 5 times
In Terraform 0.13 and above, outside of the required_providers block, Terraform con�gurations always refer to providers by their local names.
A. True
B. False
Correct Answer: A
Outside of the required_providers block, Terraform con�gurations always refer to providers by their local names.
Reference:
https://www.terraform.io/docs/language/providers/requirements.html
"Local names are module-specific, and are assigned when requiring a provider. Local names must be unique per-module.
Outside of the required_providers block, Terraform configurations always refer to providers by their local names."
https://www.terraform.io/language/providers/requirements#local-names
upvoted 4 times
What command should you run to display all workspaces for the current con�guration?
A. terraform workspace
Correct Answer: C
terraform workspace list
The command will list all existing workspaces.
Reference:
https://www.terraform.io/docs/cli/commands/workspace/list.html
Subcommands:
delete Delete a workspace
list List Workspaces
new Create a new workspace
select Select a workspace
show Show the name of the current workspace
upvoted 3 times
https://www.terraform.io/cli/commands/workspace/list
upvoted 2 times
Question #54 Topic 1
A. True
B. False
Correct Answer: B
Terraform con�gurations must declare which providers they require, so that Terraform can install and use them.
Reference:
https://www.terraform.io/docs/language/providers/con�guration.html
Which of these is the best practice to protect sensitive values in state �les?
A. Blockchain
Correct Answer: C
Use of remote backends and especially the availability of Terraform Cloud, there are now a variety of backends that will encrypt state at rest and
will not store the state in cleartext on machines running.
Reference:
https://www.terraform.io/docs/extend/best-practices/sensitive-state.html
A. Immediately
Correct Answer: B
Terraform plan and apply operations run an implicit in-memory refresh as part of their functionality, reconciling any drift from your state file before
suggesting infrastructure changes.
upvoted 2 times
How would you reference the "name" value of the second instance of this �ctitious resource?
A. element(aws_instance.web, 2)
B. aws_instance.web[1].name
C. aws_instance.web[1]
D. aws_instance.web[2].name
E. aws_instance.web.*.name
Correct Answer: A
Reference:
https://www.terraform.io/docs/con�guration-0-11/interpolation.html
output "testing" {
value = aws_iam_user.lb[1].name
}
===== output ======
Plan: 2 to add, 0 to change, 0 to destroy.
Changes to Outputs:
+ testing = "terraform-1"
upvoted 3 times
Daniel2020 3 months, 3 weeks ago
Selected Answer: B
B - aws_instance.web[1].name !!!
Index starts at 0 so the second instance would be 1 - the link below confirms this:
https://www.terraform.io/language/meta-arguments/count#referring-to-instances
upvoted 2 times
The index is not assigned to the key (name) but to the value (terraform-$(count.index). Remember this is not a list assigned to a variable, don't
reference it as a list.
So you can't call the resource by specifying the index directly onto the key like name[1] simply because the the index is assigned to a part of the
value which is a string not a list.
The only way I think is to use the element function to call the resource after which specify the index number as an argument to the function -
element(resource, index)
upvoted 1 times
https://www.terraform.io/language/functions/element
upvoted 3 times
element(list, index) - Returns a single element from a list at the given index. If the index is greater than the number of elements, this function will
wrap using a standard mod algorithm. This function only works on flat lists. Examples:
element(aws_subnet.foo.*.id, count.index)
element(var.list_of_strings, 2)
upvoted 2 times
Correct Answer: D
Reference:
https://www.terraform.io/docs/con�guration-0-11/providers.html
"Terraform uses providers to provision resources, which describe one or more infrastructure objects like virtual networks and compute instances.
Each provider on the Terraform Registry has documentation detailing available resources and their configuration options."
https://www.terraform.io/cdktf/concepts/providers
upvoted 2 times
A. True
B. False
Correct Answer: A
Reference:
https://www.terraform.io/docs/language/resources/provisioners/syntax.html
provisioner "local-exec" {
command = "echo The server's IP address is ${self.private_ip}"
}
}
upvoted 4 times
https://www.terraform.io/language/resources/provisioners/local-exec
upvoted 1 times
B is correct
upvoted 2 times
Correct Answer: C
Reference:
https://www.hashicorp.com/blog/detecting-and-managing-drift-with-terraform
"The terraform refresh command reads the current settings from all managed remote objects and updates the Terraform state to match.
Warning: This command is deprecated, because its default behavior is unsafe if you have misconfigured credentials for any of your providers. See
below for more information and recommended alternatives."
https://www.terraform.io/cli/commands/refresh
upvoted 3 times
FILL BLANK -
Which �ag would you add to terraform plan to save the execution plan to a �le?
Type your answer in the �eld provided. The text �eld is not case-sensitive and all variations of the correct answer are accepted.
"You can use the optional -out=FILE option to save the generated plan to a file on disk, which you can later execute by passing the file to terraform
apply as an extra argument. This two-step workflow is primarily intended for when running Terraform in automation.
If you run terraform plan without the -out=FILE option then it will create a speculative plan, which is a description of the effect of the plan but
without any intent to actually apply it."
https://www.terraform.io/cli/commands/plan
upvoted 1 times
Question #62 Topic 1
FILL BLANK -
What is the name of the default �le where Terraform stores the state?
Type your answer in the �eld provided. The text �eld is not case-sensitive and all variations of the correct answer are accepted.
"This state is stored by default in a local file named "terraform.tfstate", but it can also be stored remotely, which works better in a team
environment."
https://www.terraform.io/language/state
upvoted 1 times
Question #63 Topic 1
A. True
B. False
Correct Answer: A
Reference:
https://www.terraform.io/docs/con�guration-0-11/locals.html
"The expressions in local values are not limited to literal constants; they can also reference other values in the module in order to transform or
combine them, including variables, resource attributes, or other local values:"
https://www.terraform.io/language/values/locals#declaring-a-local-value
upvoted 6 times
A. list
B. map
C. tree
D. set
Correct Answer: C
Reference:
https://www.terraform.io/docs/language/expressions/type-constraints.html
https://www.terraform.io/language/expressions/type-constraints#collection-types
upvoted 2 times
Question #65 Topic 1
When running the command terraform taint against a managed resource you want to force recreation upon, Terraform will immediately destroy
and recreate the resource.
A. True
B. False
Correct Answer: B
Reference:
https://www.devopsschool.com/blog/terraform-taint-and-untaint-explained-with-example-programs-and-tutorials/
The terraform taint command informs Terraform that a particular object has become degraded or damaged. Terraform represents this by marking
the object as "tainted" in the Terraform state, and Terraform will propose to replace it in the next plan you create.
upvoted 3 times
"The terraform taint command informs Terraform that a particular object has become degraded or damaged. Terraform represents this by marking
the object as "tainted" in the Terraform state, and Terraform will propose to replace it in the next plan you create."
FYI - This command is deprecated. For Terraform v0.15.2 and later, we recommend using the -replace option with terraform apply instead. For
Terraform v0.15.2 and later, we recommend using the -replace option with terraform apply to force Terraform to replace an object even though
there are no configuration changes that would require it.
https://www.terraform.io/cli/commands/taint
upvoted 3 times
All standard backend types support state storage, locking, and remote operations like plan, apply and destroy.
A. True
B. False
Correct Answer: A
Reference:
https://www.terraform.io/docs/language/settings/backends/remote.html
"By default, Terraform uses a backend called local, which stores state as a local file on disk. You can also configure one of the built-in backends
listed in the documentation sidebar.
Some of these backends act like plain remote disks for state files, while others support locking the state while operations are being performed. This
helps prevent conflicts and inconsistencies. The built-in backends listed are the only backends. You cannot load additional backends as plugins."
https://www.terraform.io/language/settings/backends/configuration#available-backends
upvoted 3 times
Backends primarily determine where Terraform stores its state. Terraform uses this persisted state data to keep track of the resources it manages.
Since it needs the state in order to know which real-world infrastructure objects correspond to the resources in a configuration, everyone working
with a given collection of infrastructure resources must be able to access the same state data.
By default, Terraform implicitly uses a backend called local to store state as a local file on disk. Every other backend stores state in a remote service
of some kind, which allows multiple people to access it. Accessing state in a remote service generally requires some kind of access credentials,
since state data contains extremely sensitive information.
Some backends act like plain "remote disks" for state files; others support locking the state while operations are being performed, which helps
prevent conflicts and inconsistencies.
upvoted 1 times
A. Validates your expectations against the execution plan without permanently modifying state
D. Reconciles Terraform's state against deployed resources and permanently modi�es state using the current status of deployed resources
Correct Answer: A
Reference:
https://github.com/hashicorp/terraform/issues/19235
"The terraform plan command creates an execution plan, which lets you preview the changes that Terraform plans to make to your infrastructure.
By default, when Terraform creates a plan it:
Reads the current state of any already-existing remote objects to make sure that the Terraform state is up-to-date.
Compares the current configuration to the prior state and noting any differences.
Proposes a set of change actions that should, if applied, make the remote objects match the configuration."
"The plan command alone will not actually carry out the proposed changes, and so you can use this command to check whether the proposed
changes match what you expected before you apply the changes or share your changes with your team for broader review.
If Terraform detects that no changes are needed to resource instances or to root module output values, terraform plan will report that no actions
need to be taken."
https://www.terraform.io/cli/commands/plan
upvoted 3 times
You would like to reuse the same Terraform con�guration for your development and production environments with a different state �le for each.
Which command would you use?
A. terraform import
B. terraform workspace
C. terraform state
D. terraform init
Correct Answer: B
https://www.terraform.io/language/state/workspaces#when-to-use-multiple-workspaces
upvoted 2 times
Question #69 Topic 1
A. compute_instance
B. main
C. google
D. teat
Correct Answer: B
You're building a CI/CD (continuous integration/ continuous delivery) pipeline and need to inject sensitive variables into your Terraform run.
How can you do this safely?
Correct Answer: B
https://blog.gruntwork.io/a-comprehensive-guide-to-managing-secrets-in-your-terraform-code-1d586955ace1
upvoted 2 times
Your security team scanned some Terraform workspaces and found secrets stored in a plaintext in state �les.
How can you protect sensitive data stored in Terraform state �les?
Correct Answer: B
Reference:
https://www.terraform.io/docs/language/state/sensitive-data.html
In contrast to Terraform Open Source, when working with Terraform Enterprise and Cloud Workspaces, conceptually you could think about them as
completely separate working directories.
A. True
B. False
Correct Answer: A
https://www.terraform.io/cloud-docs/workspaces
upvoted 2 times
Terraform Cloud manages infrastructure collections with workspaces instead of directories. A workspace contains everything Terraform needs to
manage a given collection of infrastructure, and separate workspaces function like completely separate working directories."
upvoted 2 times
You want to know from which paths Terraform is loading providers referenced in your Terraform con�guration (*.tf �les). You need to enable
debug messages to �nd this out.
Which of the following would achieve this?
Correct Answer: A
Reference:
https://www.terraform.io/docs/cli/con�g/environment-variables.html
Although this will only output to stderr and if you need to review log file you will need to include TF_LOG_PATH=pathtofile
https://www.terraform.io/internals/debugging
upvoted 5 times
D. By an explicit call
Correct Answer: D
"The current implementation of Terraform import can only import resources into the state. It does not generate configuration. A future version of
Terraform will also generate configuration.
Because of this, prior to running terraform import it is necessary to write manually a resource configuration block for the resource, to which the
imported object will be mapped.
While this may seem tedious, it still gives Terraform users an avenue for importing existing resources."
https://www.terraform.io/cli/import/usage
upvoted 4 times
Import will find the existing resource from ID and import it into your Terraform state at the given ADDRESS.
ADDRESS must be a valid resource address. Because any resource address is valid, the import command can import resources into modules as
well as directly into the root of your state.
ID is dependent on the resource type being imported. If the ID is invalid, you'll just receive an error message.
Warning: Terraform expects that each remote object it is managing will be bound to only one resource address, which is normally guaranteed by
Terraform itself having created all objects. If you import existing objects into Terraform, be careful to import each remote object to only one
Terraform resource address. If you import the same object multiple times, Terraform may exhibit unwanted behavior.
upvoted 1 times
Question #75 Topic 1
You have a simple Terraform con�guration containing one virtual machine (VM) in a cloud provider. You run terraform apply and the VM is created
successfully.
What will happen if you delete the VM using the cloud provider console, and run terraform apply again without changing any Terraform code?
Correct Answer: D
Which of these options is the most secure place to store secrets foe connecting to a Terraform remote backend?
D. None of above
Correct Answer: A
Your DevOps team is currently using the local backend for your Terraform con�guration. You would like to move to a remote backend to begin
storing the state �le in a central location.
Which of the following backends would not work?
A. Amazon S3
B. Artifactory
C. Git
D. Terraform Cloud
Correct Answer: A
Reference:
https://secrethub.io/blog/secret-management-for-terraform/
https://www.terraform.io/cdktf/concepts/remote-backends
upvoted 4 times
https://www.terraform.io/cdktf/concepts/remote-backends
upvoted 4 times
Question #78 Topic 1
A. Terraform Cloud
B. Consul
C. Remote
D. Local
Correct Answer: D
Reference:
https://www.terraform.io/docs/language/settings/backends/con�guration.html
"By default, Terraform implicitly uses a backend called local to store state as a local file on disk. Every other backend stores state in a remote service
of some kind, which allows multiple people to access it. Accessing state in a remote service generally requires some kind of access credentials,
since state data contains extremely sensitive information."
https://www.terraform.io/language/settings/backends
upvoted 3 times
D correct
upvoted 3 times
Question #79 Topic 1
When you initialize Terraform, where does it cache modules from the public Terraform Module Registry?
B. In memory
Correct Answer: C
Reference:
https://www.terraform.io/docs/language/modules/sources.html
"A hidden .terraform directory, which Terraform uses to manage cached provider plugins and modules, record which workspace is currently active,
and record the last known backend configuration in case it needs to migrate state on the next run. This directory is automatically managed by
Terraform, and is created during initialization."
https://www.terraform.io/cli/init
upvoted 3 times
Question #80 Topic 1
You write a new Terraform con�guration and immediately run terraform apply in the CLI using the local backend.
Why will the apply fail?
A. Terraform needs you to format your code according to best practices �rst
C. The Terraform CLI needs you to log into Terraform cloud �rst
Correct Answer: C
What features stops multiple admins from changing the Terraform state at the same time?
A. Version control
B. Backend types
C. Provider constraints
D. State locking
Correct Answer: D
Reference:
https://blog.gruntwork.io/how-to-manage-terraform-state-28f5697e68fa
https://blog.gruntwork.io/how-to-manage-terraform-state-28f5697e68fa
upvoted 2 times
A fellow developer on your team is asking for some help in refactoring their Terraform code. As part of their application's architecture, they are
going to tear down an existing deployment managed by Terraform and deploy new. However, there is a server resource named
aws_instance.ubuntu[1] they would like to keep to perform some additional analysis.
What command should be used to tell Terraform to no longer manage the resource?
Correct Answer: B
Reference:
https://www.terraform.io/docs/cli/commands/state/rm.html
"You can use terraform state rm in the less common situation where you wish to remove a binding to an existing remote object without first
destroying it, which will effectively make Terraform "forget" the object while it continues to exist in the remote system."
https://www.terraform.io/cli/commands/state/rm
upvoted 5 times
B
upvoted 3 times
Question #83 Topic 1
Terraform can only manage resource dependencies if you set them explicitly with the depends_on argument.
A. True
B. False
Correct Answer: A
Reference:
https://learn.hashicorp.com/tutorials/terraform/dependencies?in=terraform/0-13
"Use the depends_on meta-argument to handle hidden resource or module dependencies that Terraform cannot automatically infer. You only need
to explicitly specify a dependency when a resource or module relies on another resource's behavior but does not access any of that resource's data
in its arguments."
https://www.terraform.io/language/meta-arguments/depends_on
upvoted 1 times
B
upvoted 1 times
A. change
B. destroy
C. provision
D. import
Correct Answer: D
While terraform allows you import existing infrastructure, it is not through the apply command.
upvoted 1 times
Correct Answer: B
Reference:
https://github.com/hashicorp/terraform-provider-null/issues/31
A version constraint is a string literal containing one or more conditions, which are separated by commas.
Version numbers should be a series of numbers separated by periods (like 1.2.0), optionally with a suffix to indicate a beta release.
= (or no operator): Allows only one exact version number. Cannot be combined with other conditions.
>, >=, <, <=: Comparisons against a specified version, allowing versions for which the comparison is true. "Greater-than" requests newer versions,
and "less-than" requests older versions.
~>: Allows only the rightmost version component to increment. For example, to allow new patch releases within a specific minor release, use the
full version number: ~> 1.0.4 will allow installation of 1.0.5 and 1.0.10 but not 1.1.0. This is usually called the pessimistic constraint operator.
https://www.terraform.io/language/expressions/version-constraints
upvoted 3 times
It fails if the = sign is missing, the same is true if the quotes are missing.
upvoted 3 times
https://www.terraform.io/language/expressions/version-constraints
upvoted 2 times
You just scaled your VM infrastructure and realized you set the count variable to the wrong value. You correct the value and save your change.
What do you do next to make your infrastructure match your con�guration?
Correct Answer: A
You need your deployment to match your config, so only way to implement changes is through terraform apply.
upvoted 1 times
A
upvoted 1 times
Terraform provisioners that require authentication can use the ______ block.
A. connection
B. credentials
C. secrets
D. ssh
Correct Answer: B
"Most provisioners require access to the remote resource via SSH or WinRM and expect a nested connection block with details about how to
connect."
"Connection blocks don't take a block label and can be nested within either a resource or a provisioner."
https://www.terraform.io/language/resources/provisioners/connection
upvoted 2 times
A
upvoted 2 times
Question #88 Topic 1
Terraform validate reports syntax check errors from which of the following scenarios?
Correct Answer: B
Reference:
http://man.hubwiz.com/docset/Terraform.docset/Contents/Resources/Documents/docs/commands/validate.html
The terraform validate command is used to validate the syntax of the terraform files. Terraform performs a syntax check on all the terraform files in
the directory, and will display an error if any of the files doesn't validate.
This command does not check formatting (e.g. tabs vs spaces, newlines, comments etc.).
https://www.typeerror.org/docs/terraform/commands/validate
https://learning-ocean.com/tutorials/terraform/terraform-validate
upvoted 5 times
You can specify a value for a var with -var in cli or terraform prompts you for a value.
upvoted 1 times
yaza 3 weeks, 2 days ago
B is false. Validate runs checks that verify whether a configuration is syntactically
valid and internally consistent, regardless of any provided variables or
existing state. It is thus primarily useful for general verification of
reusable modules, including correctness of attribute names and value types.
upvoted 2 times
B
upvoted 4 times
Question #89 Topic 1
A. count
B. name
C. source
D. version
Correct Answer: B
Reference:
https://www.terraform.io/docs/language/values/variables.html
"The name of a variable can be any valid identifier except the following: source, version, providers, count, for_each, lifecycle, depends_on, locals."
https://www.terraform.io/language/values/variables
upvoted 2 times
B
upvoted 4 times
Question #90 Topic 1
A. for_each
B. repeated
C. nesting
D. dynamic
Correct Answer: D
Reference:
https://www.hashicorp.com/blog/hashicorp-terraform-0-12-preview-for-and-for-each
https://www.terraform.io/language/expressions/dynamic-blocks
upvoted 2 times
Question #91 Topic 1
Module variable assignments are inherited from the parent module and do not need to be explicitly set.
A. True
B. False
Correct Answer: B
Reference:
https://github.com/hashicorp/terraform/issues/15818
If writing Terraform code that adheres to the Terraform style conventions, how would you properly indent each nesting level compared to the one
above it?
B. With a tab
Correct Answer: D
Reference:
https://www.terraform.io/docs/language/syntax/style.html
https://www.terraform.io/language/syntax/style#style-conventions
upvoted 6 times
Question #93 Topic 1
Correct Answer: A
Reference:
https://www.terraform.io/docs/cli/init/index.html
A. True
B. False
Correct Answer: B
Reference:
https://www.packer.io/docs/templates/hcl_templates/functions
How can you trigger a run in a Terraform Cloud workspace that is connected to a Version Control System (VCS) repository?
A. Only Terraform Cloud organization owners can set workspace variables on VCS connected workspaces
B. Commit a change to the VCS working directory and branch that the Terraform Cloud workspace is connected to
C. Only members of a VCS organization can open a pull request against repositories that are connected to Terraform Cloud workspaces
D. Only Terraform Cloud organization owners can approve plans in VCS connected workspaces
Correct Answer: B
Reference:
https://www.terraform.io/docs/cloud/vcs/index.html
"In a workspace linked to a VCS repository, runs start automatically when you merge or commit changes to version control.
A workspace is linked to one branch of a VCS repository and ignores changes to other branches. You can specify which files and directories within
your repository trigger runs. "
https://www.terraform.io/cloud-docs/run/ui#automatically-starting-runs
upvoted 3 times
Question #96 Topic 1
Terraform and Terraform providers must use the same major version number in a single con�guration.
A. True
B. False
Correct Answer: B
Reference:
https://www.terraform.io/docs/language/expressions/version-constraints.html
https://www.terraform.io/language/expressions/version-constraints#terraform-core-and-provider-versions
upvoted 4 times
Correct Answer: D
D
upvoted 2 times
B states "run anywhere". Like any cloud provider. That is just not the case. Still, migrating to another cloud provider may be less of an headache
with IAC.
upvoted 1 times
Question #98 Topic 1
When using Terraform to deploy resources into Azure, which scenarios are true regarding state �les? (Choose two.)
A. When a change is made to the resources via the Azure Cloud Console, the changes are recorded in a new state �le
B. When a change is made to the resources via the Azure Cloud Console, Terraform will update the state �le to re�ect them during the next
plan or apply
C. When a change is made to the resources via the Azure Cloud Console, the current state �le will not be updated
D. When a change is made to the resources via the Azure Cloud Console, the changes are recorded in the current state �le
Correct Answer: AC
Terraform Plan does not change the State file, It will however say the diff in the state.
The Terraform apply will make the changes to the state file to keep it consistent.
You need to deploy resources into two different cloud regions in the same Terraform con�guration. To do that, you declare multiple provider
con�gurations as follows:
What meta-argument do you need to con�gure in a resource block to deploy the resource to the `us-west-2` AWS region?
A. alias = west
B. provider = west
C. provider = aws.west
D. alias = aws.west
Correct Answer: C
Reference:
https://github.com/hashicorp/terraform/issues/451
You have declared an input variable called environment in your parent module. What must you do to pass the value to a child module in the
con�guration?
Correct Answer: C
"That module may call other modules and connect them together by passing output values from one to input values of another."
https://www.terraform.io/language/modules/develop
upvoted 7 times
If a module declares a variable with a default, that variable must also be de�ned within the module.
A. True
B. False
Correct Answer: A
Which option cannot be used to keep secrets out of Terraform con�guration �les?
A. Environment Variables
C. A Terraform provider
D. A -var �ag
Correct Answer: D
Which of the following arguments are required when declaring a Terraform output?
A. sensitive
B. description
C. default
D. value
Correct Answer: D
Your risk management organization requires that new AWS S3 buckets must be private and encrypted at rest. How can Terraform Enterprise
automatically and proactively enforce this security control?
B. By adding variables to each TFE workspace to ensure these settings are always enabled
Correct Answer: B
Reference:
https://docs.hashicorp.com/sentinel/intro/what
https://medium.com/hashicorp-engineering/enforcing-aws-s3-security-best-practice-using-terraform-sentinel-ddcd181ff4b7
upvoted 4 times
Question #105 Topic 1
A. API
B. VCS Systems
C. Shell scripts
Correct Answer: A
terraform validate validates that your infrastructure matches the Terraform state �le.
A. True
B. False
Correct Answer: A
Validate runs checks that verify whether a configuration is syntactically valid and internally consistent, regardless of any provided variables or
existing state. It is thus primarily useful for general verification of reusable modules, including correctness of attribute names and value types.
Source: https://www.terraform.io/cli/commands/validate
upvoted 2 times
Question #107 Topic 1
Correct Answer: C
FILL BLANK -
In the below con�guration, how would you reference the module output vpc_id?
Type your answer in the �eld provided. The text �eld is not case sensitive and all variations of the correct answer are accepted.
How would you reference the Volume IDs associated with the ebs_block_device blocks in this con�guration?
A. aws_instance.example.ebs_block_device.[*].volume_id
B. aws_instance.example.ebs_block_device.volume_id
C. aws_instance.example.ebs_block_device[sda2,sda3].volume_id
D. aws_instance.example.ebs_block_device.*.volume_id
Correct Answer: C
i think something is missing within the description... i think we need to choose two...
upvoted 4 times
Correct Answer: B
Source: https://www.terraform.io/language/state/locking
upvoted 4 times
Question #111 Topic 1
You just upgraded the version of a provider in an existing Terraform project. What do you need to do to install the new provider?
Correct Answer: B
A module can always refer to all variables declared in its parent module.
A. True
B. False
Correct Answer: A
When you use a remote backend that needs authentication, HashiCorp recommends that you:
A. Use partial con�guration to load the authentication credentials outside of the Terraform code
Correct Answer: B
You have a simple Terraform con�guration containing one virtual machine (VM) in a cloud provider. You run terraform apply and the VM is created
successfully.
What will happen if you terraform apply again immediately afterwards without changing any Terraform code?
D. Nothing
Correct Answer: C
A junior admin accidentally deleted some of your cloud instances. What does Terraform do when you run terraform apply?
Correct Answer: D
You have created a main.tr Terraform con�guration consisting of an application server, a database, and a load balancer. You ran terraform apply
and all resources were created successfully. Now you realize that you do not actually need the load balancer so you run terraform destroy without
any �ags What will happen?
A. Terraform will destroy the application server because it is listed �rst in the code
B. Terraform will prompt you to con�rm that you want to destroy all the infrastructure
D. Terraform will prompt you to pick which resource you want to destroy
Correct Answer: B
Which type of block fetches or computes information for use elsewhere in a Terraform con�guration?
A. provider
B. resource
C. local
D. data
Correct Answer: A
You have just developed a new Terraform con�guration for two virtual machines with a cloud provider. You would like to create the infrastructure
for the �rst time.
Which Terraform command should you run �rst?
A. terraform apply
B. terraform plan
C. terraform show
D. terraform init
Correct Answer: C
All modules published on the o�cial Terraform Module Registry have been veri�ed by HashiCorp.
A. True
B. False
Correct Answer: B
A. True
B. False
Correct Answer: B
When changing backends, Terraform will give you the option to migrate your state to the new backend. This lets you adopt backends without
losing any existing state.
To be extra careful, we always recommend manually backing up your state as well. You can do this by simply copying your terraform.tfstate file to
another location. The initialization process should create a backup as well, but it never hurts to be safe!
https://www.terraform.io/language/settings/backends/configuration
upvoted 1 times
Which of the following does terraform apply change after you approve the execution plan? (Choose two.)
A. Cloud infrastructure
D. State �le
E. Terraform code
Correct Answer: C
A Terraform backend determines how Terraform loads state and stores updates when you execute ___________.
A. apply
B. taint
C. destroy
Correct Answer: E
Correct Answer: D
You've used Terraform to deploy a virtual machine and a database. You want to replace this virtual machine instance with an identical one without
affecting the database. What is the best way to achieve this using Terraform?
A. Use the terraform state rm command to remove the VM from state �le
B. Use the terraform taint command targeting the VMs then run terraform plan and terraform apply
D. Delete the Terraform VM resources from your Terraform code then run terraform plan and terraform apply
Correct Answer: B
How do you specify a module's version when publishing it to the public Terraform Module Registry?
Correct Answer: C
ANSWER C
upvoted 2 times
A. True
B. False
Correct Answer: A
Reads the current state of any already-existing remote objects to make sure that the Terraform state is up-to-date.
Compares the current configuration to the prior state and noting any differences.
Proposes a set of change actions that should, if applied, make the remote objects match the configuration.
Answer is A
upvoted 1 times
The plan command alone will not actually carry out the proposed changes, and so you can use this command to check whether the proposed
changes match what you expected before you apply the changes or share your changes with your team for broader review.
Source: https://www.terraform.io/cli/commands/plan
upvoted 3 times