This message was deleted.
s
This message was deleted.
l
I'm not aware of a test or policy that exists that does that, but there's nothing stopping you from doing that. A policy would be very appropriate, but a unit test might be easier. And it would pick things up sooner, since the policy doesn't get applied until
up
.
r
hi @little-cartoon-10569 , thanks for your suggestion, I was trying out with Policies here, I could see they tend to fail if conditions are not met in pulumi preview, do you think that will not always work? I was more keen in policies as I am looking to make sure the new state would not break before deploying by doing pulumi up.
l
You can run policies on up only, or on certain stacks only. Some features of policies are only for certain Pulumi paid plans, but I think you can get protection from breaking custom rules in certain stacks on
pulumi up
.
However the only policy I currently use is the Pulumi-provided AwsGuard. I run it always, and I have forgotten what little I knew about policies, long ago 😞