A Chef Cookbook to help workaround the CHEF-3694 resource cloning warnings by merging resources instead.
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.


According to the discussion on the CHEF-3694 ticket, resource cloning, a technique many official community cookbooks rely on, is being deprecated. As such, you get a lot of warnings like this when using off-the-shelf cookbooks:

[2014-01-24T16:15:55+00:00] WARN: Cloning resource attributes for package[perl] from prior resource (CHEF-3694)
[2014-01-24T16:15:55+00:00] WARN: Previous package[perl]: /tmp/vagrant-chef-1/chef-solo-1/cookbooks/perl/recipes/default.rb:26:in `block in from_file'
[2014-01-24T16:15:55+00:00] WARN: Current  package[perl]: /tmp/vagrant-chef-1/chef-solo-1/cookbooks/iptables/recipes/default.rb:21:in `from_file'

This cookbook monkey-patches Chef to try a new idea...instead of cloning resources, it tries to reuse them and merge their actions together. This circumvents the warning and seems to make all the cookbooks that I am using function properly.

This is not well-tested at this time. It works for the set of community and custom cookbooks we have used it with, which includes a lot of the popular ones. Your Mileage May Vary. See my larger discussion of the issue and the solution discovery on my blog post about this.