|
#! /bin/bash |
|
|
|
### ### |
|
# This script assumes you're kicking things off from a clean install of Ubuntu # |
|
# You're welcome to skip parts which you've already installed! # |
|
### ### |
|
|
|
# Required - install curl |
|
sudo apt-get install curl |
|
|
|
# Optional - install libssl for ssl support |
|
sudo apt-get install libssl-dev |
|
|
|
# Get Node and build |
|
echo 'export PATH=$HOME/local/bin:$PATH' >> ~/.bashrc |
|
. ~/.bashrc |
|
mkdir ~/local |
|
mkdir ~/node-latest-install |
|
cd ~/node-latest-install |
|
curl http://nodejs.org/dist/node-latest.tar.gz | tar xz --strip-components=1 |
|
|
|
# Add '--without-ssl' if not compiling with ssl support to avoid errors |
|
./configure --prefix=~/local |
|
make install |
|
|
|
# Optional - install NPM (it'll make your life with node much easier!) |
|
curl http://npmjs.org/install.sh | sh |
|
|
|
# Optional - install Express (a great module to ease server creation) |
|
npm install express |
|
|
|
### ### |
|
# That's it, go Node! # |
|
### ### |
Leave a Comment
Your email address will not be published. Required fields are marked *