3 ms·
I haven't played with Pulumi in a long while, because we decided that for hiring reasons we'd hold our nose and use the aggressively stupid terraform because at
by mdaniel 3y ago
I haven't played with Pulumi in a long while, because we decided that for hiring reasons we'd hold our nose and use the aggressively stupid terraform because at least it's known stupid
But I just fired up a recent version of Pulumi and can say that there is "no long live Pulumi" in its current state because they aped terraform so much it falls prey to the exact same stupidity as terraform, only now featuring their own bugs <https://github.com/pulumi/pulumi-aws-native/issues/108 https://github.com/pulumi/pulumi-aws-native/issues/108>
$ pulumi new aws-native-go
$ grep NewBucket main.go
bucket, err := s3.NewBucket(ctx, "existing-bucket-name", nil)
$ aws s3api list-buckets --query 'Buckets[*].Name' | grep existing-bucket-name
"existing-bucket-name",
$ pulumi preview
@ previewing update....
+ aws-native:s3:Bucket existing-bucket-name create
so: (1) I see, you required that I give you live AWS credentials, but you didn't use them for shit (2) this is not legacy terraform behavior this is using their own provider so they are not beholden to the incredibly misguided decisions Hashicorp made
You can retort "but muh state file!!1" all you want, if I $(pulumi import 'aws-native:s3:Bucket' existing-bucket-name existing-bucket-name) and then run $(pulumi preview) it for damn sure uses any credentials to interrogate the resource so let's just skip the pretense that one needs a state file to straight-face check proposed changes. Asking the user to learn the crazy import syntax for every resource across every provider just to do the work of a computer running a HEAD request against an API is stupid
Or, if one wants to take the terraform approach of hurp durp I dunno if any resources exist, then don't require live credentials during the plan phase so that everyone is on exactly the same page about what will and won't happen for each phase