Terraform Associate Exam QuestionsBrowse all questions from this exam

Terraform Associate Exam - Question 84


A terraform apply can not _________ infrastructure.

Show Answer
Correct Answer: D

The terraform apply command is used to apply the changes required to reach the desired state of the configuration. It can change (update), destroy, and provision infrastructure, but importing existing infrastructure into the state file is performed using the terraform import command. Therefore, terraform apply cannot import infrastructure.

Discussion

9 comments
Sign in to comment
alejandro_torres
Aug 3, 2023

deprecated question https://www.hashicorp.com/blog/terraform-1-5-brings-config-driven-import-and-checks

LunarPhobiaOption: D
Jul 26, 2023

D as importing requires a separate command from Apply

antivrilleeOption: D
Sep 2, 2022

https://www.educative.io/answers/what-is-the-command-to-destroy-infrastructure-in-terraform

root_i_amOption: D
Sep 29, 2022

The answer is D. While terraform allows you import existing infrastructure, it is not through the apply command.

iDiddy
Jun 18, 2023

import is an explicit command

Clapton79
Nov 10, 2023

Not any more, you can have an import {} clause so I guess this question is no longer valid. https://www.hashicorp.com/blog/terraform-1-5-brings-config-driven-import-and-checks

dnscloud02
Sep 24, 2022

Not sure --> Terraform can import existing infrastructure resources. This functionality allows you take resources you created by some other means and bring them under Terraform management.

antivrillee
Oct 5, 2022

The question is about the command "terraform apply" and not terraform

vadeemkaa
Dec 22, 2022

Answer D. terraform import command

Power123
Mar 31, 2023

Answer is D

SureNot
Jun 12, 2024

Terraform v1.5.0 and later supports import blocks... A bit old question...