[chef] Re: Re: undefined method `[]' for nil:NilClass


Chronological Thread 
  • From: "Oliver Rojo" < >
  • To:
  • Subject: [chef] Re: Re: undefined method `[]' for nil:NilClass
  • Date: Thu, 18 Feb 2010 08:56:17 +0000


----- Original Message -----
From: Alex Soto
[mailto:
To: 

Sent: Thu, 18 Feb 2010
08:45:31 +0000
Subject: [chef] Re: undefined method `[]' for nil:NilClass


> @node is how to get node attributes unless you defined a variable named
> localhost.

Tried changing @localhost to @node but the same error still exists.
> 
> On Feb 18, 2010, at 12:37 AM, Oliver Rojo wrote:
> 
> > How can i fix this error?
> > 
> > Chef::Mixin::Template::TemplateError (undefined method `[]' for
> nil:NilClass)
> > 
> > I'm using:
> > 
> > <%= @localhost["ipaddress"] %> on one of my template and suddenly after
> running chef-client, it stops with the above error.
> > 
> > Please help!
> > 
> > Oliver
> 
> 


  • [chef] Re: Re: undefined method `[]' for nil:NilClass, Oliver Rojo, 02/18/2010

Archive powered by MHonArc 2.6.16.

§