TA-002-P · Question #134
Terraform import command can import resources into modules as well directly into the root of your state.
The correct answer is A. True. True. The terraform import command supports importing existing infrastructure into both the root module and into child modules. To import into a module, you specify the full resource address including the module path, for example: terraform import…
Question
Terraform import command can import resources into modules as well directly into the root of your state.
Options
- ATrue
- BFalse
How the community answered
(64 responses)- A95% (61)
- B5% (3)
Explanation
True. The terraform import command supports importing existing infrastructure into both the root module and into child modules. To import into a module, you specify the full resource address including the module path, for example: terraform import module.mymodule.aws_instance.example i-1234567890abcdef0. This tells Terraform to associate the existing resource with the resource defined inside that module in your configuration.
Topics
Community Discussion
No community discussion yet for this question.