- From: Chaim Keren-Tzion <
>
- To:
- Subject: [chef] Role Attributes not working in shef?
- Date: Sun, 11 Dec 2011 19:22:06 +0200
I have the following code in a role which I have verified is loaded:
default_attributes(
:syslogserver => {
:hostname => "sysloger01",
:ip => [
"10.4.0.5",
"10.16.0.70"
]
},
:oldvservers => "32"
)
However...
When I enter the shef shell with: 'shef -z -c /etc/chef/shef.rb' even though it shows that the role is loaded and even if I do:
chef >
roles.show("mainrole")
=> role[mainrole]
I still only get results like these:
chef > node[:syslogserver]
=> nil
chef > node[:syslogserver][:ip]
NoMethodError: undefined method `[]' for nil:NilClass
chef > node[:oldvservers]
=> nil
chef > node["oldvservers"]
=> nil
Any idea how I can get the attributes populated in shef? or is there another way I can test them?
TAI,
Chaim
- [chef] Role Attributes not working in shef?, Chaim Keren-Tzion, 12/11/2011
Archive powered by MHonArc 2.6.16.