Created
February 23, 2012 17:01
-
-
Save ivey/1893755 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namenode = search(:node, "chef_environment:#{node.chef_environment} AND role:hadoop_namenode_server").first | |
vars = { :options => node[:hadoop][:core_site] } | |
vars[:namenode_ip] = namenode[:ipaddress] if namenode | |
template "/etc/hadoop-#{node[:hadoop][:version]}/conf.chef/core-site.xml" do | |
mode 0750 | |
owner "hdfs" | |
group "hdfs" | |
action :create | |
variables vars | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment