[chef] ruby code in lwRp decalaration


Chronological Thread 
  • From: Dorian Jaminais < >
  • To: " " < >
  • Subject: [chef] ruby code in lwRp decalaration
  • Date: Fri, 31 May 2013 18:51:15 +0200

Hi all,

In a LRWP resource definition (the file in ./resources), is it possible to do something like :
actions :install
default_action :install
attribute :name, :kind_of => String, :name_attribute => true
attribute :repository, :kind_of => String, :default => node[:name]['repository']


Unfortunately :name is not yet defined when my third line gets executed.
Is there a way to access it from within that file (I need it to define other attributes default)?

--
Dorian JAMINAIS
System Administrator
+33 6 95 10 95 37






Archive powered by MHonArc 2.6.16.

§