PageRenderTime 8ms CodeModel.GetById 1ms app.highlight 4ms RepoModel.GetById 1ms app.codeStats 0ms


Relevant Search: With Applications for Solr and Elasticsearch

For more in depth reading about search, ranking and generally everything you could ever want to know about how lucene, elasticsearch or solr work under the hood I highly suggest this book. Easily one of the most interesting technical books I have read in a long time. If you are tasked with solving search relevance problems even if not in Solr or Elasticsearch it should be your first reference. Amazon Affiliate Link
Shell | 45 lines | 36 code | 4 blank | 5 comment | 1 complexity | 1a68184ae622cc7965da26f39138f6e7 MD5 | raw file
 1#!/bin/bash -ex
 3# Java
 4perl -p -i -e 's/^\# (.*partner)$/$1/g' /etc/apt/sources.list
 5apt-get update
 6echo "
 7sun-java6-bin shared/accepted-sun-dlj-v1-1 boolean true
 8sun-java6-bin shared/present-sun-dlj-v1-1 note
 9sun-java6-jdk shared/accepted-sun-dlj-v1-1 boolean true
10sun-java6-jdk shared/present-sun-dlj-v1-1 note
11sun-java6-jre shared/accepted-sun-dlj-v1-1 boolean true
12sun-java6-jre shared/present-sun-dlj-v1-1 note
13sun-java6-jre sun-java6-jre/jcepolicy note
14sun-java6-jre sun-java6-jre/stopthread boolean true
15" | debconf-set-selections
16apt-get -y install sun-java6-jdk
18# RabbitMQ
19echo "rabbitmq-server rabbitmq-server/upgrade_previous note" |\
20    debconf-set-selections
22# Chef
23echo "deb `lsb_release -cs`-0.10 main" |\
24    tee /etc/apt/sources.list.d/opscode.list
25wget -O - |\
26    apt-key add -
27apt-get update
28echo "
29chef chef/chef_server_url string http://localhost:4000
30chef-server-webui chef-server-webui/admin_password string ub3rs3kr4t
31chef-solr chef-solr/amqp_password string ub3rs3kr4t
32" | debconf-set-selections
33apt-get -y install chef-server
35# Cleanup
36for x in chef-client chef-server-webui chef-server chef-expander chef-solr \
37    rabbitmq-server couchdb ; do
38    update-rc.d -f $x remove &
39    invoke-rc.d $x stop &
40    wait
42chown -R chef:chef /etc/chef /var/lib/chef /var/log/chef
43chown -R rabbitmq:rabbitmq /etc/rabbitmq /var/lib/rabbitmq /var/log/rabbitmq
44chown -R couchdb:couchdb /etc/couchdb /var/lib/couchdb /var/log/couchdb
45rm -rf /etc/chef/client.pem /var/lib/rabbitmq/* /var/lib/couchdb/*