Hi,
you can use Ohai variable node['hostname'] or environment variable via
ENV['something'].
Damn Eric beat me to it..
in terminal open up chef-shell. It'll allow you to experiment without
having to execute the whole recipe.
Cheers
Alex-
On Sun, Apr 27, 2014 at 7:58 PM, Tomasz Chmielewski
< >
wrote:
How can I use the $HOSTNAME variable in a recipe?
I need something which would fit here:
remote_file "/tmp/$HOSTNAME.tar.xz" do
source
"https://user: :port/aaa/$HOSTNAME.tar.xz"
owner "root"
group "root"
mode 00600
not_if { ::File.exists?("/some/path/here") }
end
--
Tomasz Chmielewski
http://wpkg.org [1]
Archive powered by MHonArc 2.6.16.