-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
knife cookbook doc fails if node attributes are referenced in light-weight resources. #24
Comments
@RobertNorthard Are you willing to give us a Gist with a bit more detail. Perhaps the result of |
I'm running into this too. Knife Output:
Relevant section of code: 34 attribute :checksum, kind_of: [String, NilClass], default: nil
35 attribute :backup, kind_of: [Integer, FalseClass], default: 5
36 if node['platform_family'] == 'windows'
37 attribute :inherits, kind_of: [TrueClass, FalseClass], default: true
38 attribute :rights, kind_of: Hash, default: nil
39 end
40
41 version = Chef::Version.new(Chef::VERSION[/^(\d+\.\d+\.\d+)/, 1]) |
Signed-off-by: Robert Northard <[email protected]>
Pull request, #29 should resolve the initial issue with the node object being undefined. However as the run_context is nill it won't be able to resolve any of the node's attributes and hence node.hi or node['hi'] will throw a nil class exception. |
Any updates on handle node object in resources for documentation ? |
Not had time to work on this sorry 🙁 |
Knife cookbook doc fails if node attributes are referenced in light-weight resources.
attribute :attribute_name, :kind_of => value, :default => node['org_cb']['attr']
The text was updated successfully, but these errors were encountered: