Skip to content

Instantly share code, notes, and snippets.

@alexforrow
Created November 2, 2010 13:32
Show Gist options
  • Save alexforrow/659609 to your computer and use it in GitHub Desktop.
Save alexforrow/659609 to your computer and use it in GitHub Desktop.
Use of search for template
nodes = search(:node, "*:*")
template "/etc/ssh/ssh_known_hosts" do
source "ssh_known_hosts.erb"
mode 0644
owner "root"
group "root"
variables(:nodes => nodes)
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment