I've read the pulumi architecture docs, but I'm not grokking why pulumi has this separate state off to the side reflecting the last-deployed state. AFAICT, a diff against what exists now is always required anyway?
02/04/2020, 4:39 PM
Pulumi does not diff against the cloud by default.
But even if you do do a refresh (which reconciles state with the cloud), it is frequently the case that the state recoverable from the cloud providers is not a sufficient description of the desired state, so the previously applied desired state is still necessary for diffing.
You can see this in many others IaC ecosystems - Terraform of course, but also the
annotation used by kubectl.
02/04/2020, 4:49 PM
ah-ha, I had presumed that
was doing a
I confess to not being familiar with terraform. I'm currently tinkering with pulumi and AWS CDK; the latter's lack of distinct "last-applied" state is what motivated the question.
02/04/2020, 4:56 PM
Well - solutions like ARM and CloudFormation which are 100% cloud-hosted may very well be managing last applied configuration purely within the cloud backend. It would be mostly invisible to you - but could still be there. In principal, the same is true if you use the Pulumi Service backend - you effectively never need to think about state files.