3 ms·
Terraform is also mostly declarative. You write the state you would like resources to be in. When you run terraform plan, it tells you how the state might end
by peterwwillis 6y ago
Terraform is also mostly declarative.
You write the state you would like resources to be in. When you run terraform plan, it tells you how the state might end up. You run terraform apply and then get to find out what actually happens.
Will it create the resources how I expect? What will the resource's properties be? Will it fail half way into the changes and stop in a broken state? Will it blow away changes without asking/showing me first? Will it refuse to do anything? Who knows.
It's a guessing game. The only way to be sure of what it will or won't do is to write procedural code and tests, so at least you know what decisions it will and won't make.
'Declarative' is just us fooling ourselves that we can make complexity easy to deal with.