- From: <
>
- To:
- Subject: [chef] Need to pass argument from recipe to another in cookbook
- Date: Mon, 22 Sep 2014 02:56:05 -0700 (PDT)
Hi,
I had a cookbook with multiple recipes, in one of them having resources like
Path /root/chef-repo/cookbooks/rollback/recipes/default.rb
ruby_block "Create a directry for backup" do
block do
FileUtils.mkdir node['backup_path'] unless Dir.exists? node['backup_path']
$s=FileUtils.mkdir node['new_directory']
puts "directory#{$s}"
end
end
I need to pass this global variable $s to another chef resources in another
recipe like Path /root/chef-repo/cookbooks/rollback/recipes/xxxx.rb, if is is
possible how can i get that value during at run time or in any other way?
Thanks in advance,
Ganesan.A
- [chef] Need to pass argument from recipe to another in cookbook, ganesan15785, 09/22/2014
Archive powered by MHonArc 2.6.16.