|
|
|
|
|
by mannyv
388 days ago
|
|
Terraform is hard because it can be a different way of thinking about deployments and your infrastructure. And since it's declarative you can't do conditionals in normal ways. What I used to do is create things in my target environment then try to recreate them in terraform (without the import, because import didn't really work so well). Then do an apply/plan and see what changes were listed. What I would do today is ask ChatGPT for terraform for specific things, then see what it outputs, compare it with the registry, then do the apply. Terraform is half the battle, the other half is figuring out how the specific provider represents their stuff...which is why ChatGPT is helpful. Oh, and also look at your provider's examples. You presumably know how things work in your provider, so looking at their terraform registry will help you figure out how they model stuff in terraform so you can model your stuff in terraform. |
|