-
Notifications
You must be signed in to change notification settings - Fork 58
/
configure_ubuntu-12.04.sh
executable file
·61 lines (50 loc) · 1.69 KB
/
configure_ubuntu-12.04.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
#!/bin/bash
# Note: pushd/popd only work in bash
sudo apt-get install -y \
curl emacs unzip python-dev python-setuptools build-essential erlang-nox erlang-dev \
libevent-dev git golang mercurial openjdk-7-jdk ruby rubygems haskell-platform
sudo easy_install pip ws4py gevent gevent-websocket tornado twisted txws supervisor
# Clone master
git clone git://github.com/ericmoritz/wsdemo.git wsdemo
# Update sysctl
sudo cp wsdemo/etc/sysctl.conf /etc/
sudo sysctl -p
# install the wsdemo_monitor package
sudo easy_install wsdemo/priv/wsdemo_monitor
# install pypy
pushd wsdemo/competition
if [ ! -d ./pypy-1.9 ]; then
# TODO make this platform independant
curl http://cdn.bitbucket.org/pypy/pypy/downloads/pypy-1.9-linux64.tar.bz2 | tar xj
fi
curl http://python-distribute.org/distribute_setup.py | ./pypy-1.9/bin/pypy
./pypy-1.9/bin/easy_install pip
./pypy-1.9/bin/pip install tornado ws4py twisted txws
popd
# install Node
mkdir src
pushd src
curl http://nodejs.org/dist/v0.8.0/node-v0.8.0.tar.gz | tar xz
pushd node-v0.8.0
./configure && make && sudo make install
popd
popd
# install Play
pushd wsdemo/competition
if [ ! -d ./play-2.0.1 ]; then
curl -O http://download.playframework.org/releases/play-2.0.1.zip
unzip play-2.0.1.zip
fi
popd
npm install websocket ws
sudo go get code.google.com/p/go.net/websocket
sudo gem install em-websocket
sudo cabal update
sudo cabal install snap-server snap-core websockets websockets-snap
sudo apt-get install -y libadns1-dev
echo -e "y\ny\no conf prerequisites_policy follow\no conf commit" | sudo cpan
sudo cpan Protocol::WebSocket
sudo cpan YAML
sudo cpan EV
sudo cpan EV::ADNS
yes | sudo cpan IO::Stream