Here's a fork of adam's hoptoad handler which I've made work with chef 0.9.6.
(I think adam's code must have been for an older or newer version of chef.)
To install it place the chef-handler-hoptoad.rb file in /etc/chef, and then add
these two lines to client.rb
===================
require '/etc/chef/chef-handler-hoptoad'
exception_handlers << Chef::Handler::Hoptoad.new(:api_key=>XXX)
Hoptoad will now start emailing exceptions to you... e.g....
===================
Error Message:
Chef::Exceptions: No version specified, and no candidate version available for munin-node
Where:
cl0#run
/usr/lib/ruby/gems/1.8/gems/chef-0.9.6/bin/../lib/chef/provider/package.rb, line 50
Request:
params:
action: run
controller: cl0
rails_root: /
url: "http://localhost/"
Session:
? !ruby/symbol data
: {}
Environment:
PATH: "/usr/local/bin:/usr/local/sbin:/bin:/sbin:/usr/bin:/usr/sbin:/usr/lib/ruby/gems/1.8/bin"
PWD: /etc/sv/chef-client
RAILS_ENV: production
Backtrace:
/usr/lib/ruby/gems/1.8/gems/chef-0.9.6/bin/../lib/chef/provider/package.rb:50:in action_install' /usr/lib/ruby/gems/1.8/gems/chef-0.9.6/bin/../lib/chef/runner.rb:50:in
send'
/usr/lib/ruby/gems/1.8/gems/chef-0.9.6/bin/../lib/chef/runner.rb:50:in run_action' /usr/lib/ruby/gems/1.8/gems/chef-0.9.6/bin/../lib/chef/runner.rb:107:in
converge'
...
--
John Merrells
http://johnmerrells.com
+1.415.244.5808