logoalt Hacker News

colechristensenyesterday at 8:27 PM1 replyview on HN

There are three things:

* Your terraform code

* The state terraform holds which is what it thinks your infrastructure state is

* The actual state of your infrastructure

>Why don't cloud providers have a nice way for tools like TF to query the current state of the infra?

What a terraform provider is is code that queries the targeted resources through whatever APIs they provide. I guess you could argue these APIs could be better, faster, or more tuned towards infrastructure management... but gathering state from whatever resources it manages is one of the core things terraform does. I'm not sure what you're asking for.


Replies

fragmedeyesterday at 8:30 PM

for the plan file to be updated to the state of the world in a non-conusing way so that apply does the right thing without a chance it's gonna blow things up.

show 1 reply