Skip to content

Instantly share code, notes, and snippets.

@suzuki suzuki/default.rb

Created Nov 20, 2014
Embed
What would you like to do?
ELasticsearch recipe
apt_repository 'elasticsearch-stable' do
uri 'http://packages.elasticsearch.org/elasticsearch/1.4/debian'
distribution 'stable'
components ['main']
key 'http://packages.elasticsearch.org/GPG-KEY-elasticsearch'
not_if do
File.exists?('/etc/apt/source.list/d/elasticsearch.list')
end
end
%w{openjdk-7-jdk elasticsearch}.each do |pkg|
package pkg do
action :install
end
end
template '/etc/elasticsearch/elasticsearch.yml' do
owner 'root'
group 'root'
mode 0644
notifies :reload, 'service[elasticsearch]'
end
service 'elasticsearch' do
action [:enable, :start]
supports :status => true, :restart => true, :reload => true
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.