References for writing Chef idempotent

I'm looking for some guidance or reference to get started with writing idempotent style in Chef.

Most Chef resources are idempotent by design (file, package, etc.) but when you start using execute and other similar resources they may have side-effects. You'll want to make your code have fewer side-effects by using guards to only execute when you're absolutely sure you should.

https://docs.chef.io/resource_common.html#guards

1 Like