Exam Terraform Associate All QuestionsBrowse all questions from this exam
Question 115

A junior admin accidentally deleted some of your cloud instances. What does Terraform do when you run terraform apply?

    Correct Answer: C

    When you run 'terraform apply', Terraform compares the current state of your infrastructure with the desired state specified in your configuration files. If any instances are found to be missing, Terraform will recreate only those instances to match the desired state. It does not rebuild the entire infrastructure, nor does it stop and generate an error. Terraform's purpose is to ensure the actual state matches the desired state as defined in your configuration files, and it will take appropriate actions to achieve this.

Discussion
legendary7Option: C

C Terraform would refresh and check that the Current State in the state file is not thesame as the Desired State. Terraform will check its configuration resource files and if it finds a resource that is present in the state file but not in the Desired state, it will create it

shopkittyOption: C

vote for C

Ni33Option: C

C is the correct answer !

Power123Option: C

C is correct

adoubanOption: C

Deleting instance from cloud console will result terraform to create instance again to match what written in tf config files

amanpOption: C

Answer is C.

BurakkoOption: C

the correct answer is C.

090200fOption: C

C is the correct ans

recep38Option: D

it is very clear

duffyduckOption: C

The Answer is C