sudo apt-get install fail2ban
sudo apt-get install htop
sudo apt-get install git
sudo apt-get install build-essential
sudo apt-get install libboost-all-dev
sudo apt-get install cmake
Python.h, etc
sudo apt-get install python-dev
For easy install:
sudo apt-get install python-setuptools
Now pip:
sudo easy_install pip
sudo pip install virtualenv
Important C libararies need for lxml & friends
# needed for lxml
sudo apt-get install libxml2-dev libxslt-dev
sudo apt-get install mysql-client libmysqlclient-dev
Numerical analysis:
sudo pip install numpy matplotlib ipython
From https://github.com/mapnik/mapnik/wiki/UbuntuInstallation
sudo apt-get install osm2pgsql
sudo apt-get install -y python-software-properties
sudo apt-get install software-properties-common
sudo add-apt-repository ppa:mapnik/v2.1.0
sudo apt-get update
sudo apt-get install libmapnik mapnik-utils python-mapnik
sudo pip install nik2img
Out of the box, we have problems with some PIL zip decoder. See here: https://milkator.wordpress.com/2012/10/26/install-and-setup-tilestache/
sudo apt-get install libjpeg8 libjpeg62-dev libfreetype6 libfreetype6-dev
sudo pip uninstall PIL
sudo ln -s /usr/lib/x86_64-linux-gnu/libjpeg.so /usr/lib
sudo ln -s /usr/lib/x86_64-linux-gnu/libfreetype.so /usr/lib
sudo ln -s /usr/lib/x86_64-linux-gnu/libz.so /usr/lib
sudo pip install -U PIL
From https://github.com/DennisOSRM/Project-OSRM/wiki/Building%20OSRM
sudo apt-get install build-essential git scons pkg-config libprotoc-dev libprotobuf7 \
protobuf-compiler libprotobuf-dev libosmpbf-dev libpng12-dev \
libbz2-dev libstxxl-dev libstxxl-doc libstxxl1 libxml2-dev \
libzip-dev libboost-thread-dev libboost-system-dev libboost-regex-dev \
libboost-filesystem-dev lua5.1 liblua5.1-0-dev libluabind-dev
for running the tests (this is 279MB!):
sudo apt-get install rubygems osmosis
sudo gem install bundler
set up a swap file, the micro memory is too small to compile all of it.
From http://inprvt.com/index.php/blogs/entry/how-to-add-swap-space-on-a-linux-based-ec2-server
dd if=/dev/zero of=/swapfile1 bs=1024 count=524288
mkswap /swapfile1
swapon /swapfile1
(I'm not going to automount it)
Now compile the package:
git clone https://github.com/DennisOSRM/Project-OSRM.git
cd Project-OSRM && scons
See: http://igraph.wikidot.com/installing-python-igraph-on-linux
sudo add-apt-repository ppa:igraph/ppa
sudo apt-get update
sudo apt-get install python-igraph
# For dionysus, for alpha shapes.
# http://www.mrzv.org/software/dionysus/index.html
# needs CGAL and cmake and boost
hg clone http://hg.mrzv.org/Dionysus/
cd Dionysus
hg up tip
mkdir build
cd build
cmake ..
make
Following http://tghw.com/blog/multiple-django-and-flask-sites-with-nginx-and-uwsgi-emperor
sudo apt-get install nginx uwsgi
Configure uwsgi
curl "https://gist.github.com/ekfriis/5075470/raw/uwsgi.conf" | sudo tee /etc/init/uwsgi.conf
sudo mkdir -p /var/log/uwsgi
sudo mkdir -p /etc/uwsgi/apps-available
sudo mkdir -p /etc/uwsgi/apps-enabled
curl -O http://osm-metro-extracts.s3.amazonaws.com/los-angeles.osm.pbf
osm2pgsql -c -G -U scientraffic -d scientraffic_db los-angeles.osm.bz2 --style=/usr/local/share/osm2pgsql/default.style
This doesn't work - not enough memory (I think). Let's do the heavy lifting on the laptop.
To tunnel, I had to change md5->trust for host in the line
#/etc/postgresql/9.1/main/pg_hba.conf
host all all 127.0.0.1/32 trust
Then restart with sudo /etc/init.d/postgresql restart
ssh -L 9999:127.0.0.1:5432 friis@www.scientraffic.com
osm2pgsql -c -G -U scientraffic -d scientraffic_db los-angeles.osm.bz2 --style=/usr/local/share/osm2pgsql/default.style --port 9999 --host localhost
From https://github.com/joyent/node/wiki/Installing-Node.js-via-package-manager
sudo apt-get install python-software-properties python g++ make
sudo add-apt-repository ppa:chris-lea/node.js
sudo apt-get update
sudo apt-get install nodejs npm
sudo npm install -g carto millstone optimist