In the chef execute resource, the "creates" property/parameter... what does that do exactly? I'm sure it's straightforward, but can someone explain please? Thank you.
https://docs.chef.io/resource_execute.html
creates Ruby Type: String Prevent a command from creating a file when that file already exists.
It tests for the file that is specified before running the execute. If the file already exists, it will not run that execute. If the file does not exist, it will run the execute.
creates "/foo"
is equivalent to not_if { File.exist?("/foo") }
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With