Skip to content

Instantly share code, notes, and snippets.

@jens
Created February 4, 2013 20:30
Show Gist options
  • Save jens/4709481 to your computer and use it in GitHub Desktop.
Save jens/4709481 to your computer and use it in GitHub Desktop.
Error with sensu using chef-client v 11
================================================================================
Recipe Compile Error in /var/chef/cache/cookbooks/sensu/libraries/json_file.rb
================================================================================
NoMethodError
-------------
undefined method `attribute' for Chef::Resource::JsonFile:Class
Cookbook Trace:
---------------
/var/chef/cache/cookbooks/sensu/libraries/json_file.rb:49:in `<class:JsonFile>'
/var/chef/cache/cookbooks/sensu/libraries/json_file.rb:48:in `<top (required)>'
Relevant File Content:
----------------------
/var/chef/cache/cookbooks/sensu/libraries/json_file.rb:
42: set_group unless @new_resource.group.nil?
43: set_mode unless @new_resource.mode.nil?
44: end
45: end
46: end
47:
48: class Chef::Resource::JsonFile < Chef::Resource::File
49>> attribute :content, :kind_of => Hash
50:
51: def initialize(name, run_context=nil)
52: super
53: @resource_name = :json_file
54: @provider = Chef::Provider::JsonFile
55: end
56: end
57:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment