Recall & Review
beginner
What does the
terraform apply command do?It executes the planned changes to create, update, or delete infrastructure resources as defined in the Terraform configuration files.
Click to reveal answer
beginner
Why is it recommended to run
terraform plan before terraform apply?Because
terraform plan shows the changes Terraform will make, helping you review and avoid unexpected modifications before applying them.Click to reveal answer
intermediate
What happens if you run
terraform apply without a saved plan file?Terraform will create a new plan automatically and prompt you to approve it before applying the changes.
Click to reveal answer
intermediate
How can you apply a previously saved plan file with Terraform?
Use
terraform apply <plan-file-name> to apply the exact changes from the saved plan without re-planning.Click to reveal answer
intermediate
What is the purpose of the
-auto-approve flag in terraform apply?It skips the interactive approval prompt and applies changes immediately, useful for automation but should be used carefully.
Click to reveal answer
What does
terraform apply primarily do?✗ Incorrect
terraform apply executes the changes to infrastructure as defined in the configuration.
Which command should you run before
terraform apply to review changes?✗ Incorrect
terraform plan shows the changes Terraform will make before applying.
What happens if you use
terraform apply -auto-approve?✗ Incorrect
The -auto-approve flag skips the confirmation prompt and applies changes immediately.
How do you apply a saved plan file named
myplan.tfplan?✗ Incorrect
Use terraform apply <plan-file> to apply a saved plan.
If you run
terraform apply without a plan file, what happens?✗ Incorrect
Terraform automatically creates a plan and prompts for approval before applying.
Explain the purpose and typical workflow of the
terraform apply command.Think about how Terraform changes your cloud setup after planning.
You got /4 concepts.
Describe how to safely automate Terraform apply in a CI/CD pipeline.
Automation means no manual approval but still safe.
You got /4 concepts.