There are a lot of good example Opscode cookbooks out there. Unfortunately they can be hard to find. People are not submitting them to the Opscode Cookbook repository. Its still hard to untangle your own cookbooks into something that can be put in a sharable format I guess.
Right now, the most productive way to find cookbooks seems to be to search github. I always do a search before I write my own. Google searches are tough since “chef”, “cookbooks” are overloaded from the “real cooking” domain. And if you put in some package name, you tend to get announcements about the package and a mention about Opscode, but rarely about an Opscode Cookbook for that package.
Today I discovered that I needed a cookbook to install jruby. So after a useless Google Search. I did a search “jruby cookbook” on github and soon found Theo Cushion’s cookbook clone with a jruby addition.
Looks like Theo Cushion’s github account no longer exists. Another jruby cookbook can be found Jorge Falcão at https://github.com/jlbfalcao/chef-jruby
Its better to not have to write it yourself! My thanks to Theo, Jorge and the many others who share their code.