Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save gavinengel/6519700 to your computer and use it in GitHub Desktop.
Save gavinengel/6519700 to your computer and use it in GitHub Desktop.
# I know it's an ugly, but it works for me. Complete installation process:
sudo apt-get update; sudo apt-get upgrade -y; sudo apt-get update;
sudo apt-get install -y python-software-properties python g++ make;
### 'add-apt-repository' not available on my Ubuntu 12.10 by default, so the next line adds it.
### more info found here: http://stackoverflow.com/questions/13018626/add-apt-repository-not-found
sudo apt-get install software-properties-common -y;
###
sudo add-apt-repository ppa:chris-lea/node.js -y;
sudo apt-get update;
sudo apt-get install -y nodejs;
sudo apt-get install -y build-essential g++ curl libssl-dev apache2-utils git libxml2-dev;
cd ~;
sudo npm install forever -g;
mkdir git;
cd ~/git;
git clone git://github.com/ajaxorg/cloud9.git;
git clone https://github.com/creationix/nvm.git ~/.nvm;
source ~/.nvm/nvm.sh;
nvm install v0.8.25; nvm use v0.8.25;
sudo npm install packager; # Packager needs node version 8, so we are providing it with nvm.
cd cloud9; sed -i -e 's/~//g' package.json; sudo npm install;
nvm install v0.10.17; nvm use v0.10.17;
sudo ~/git/cloud9/bin/cloud9.sh -l my.host.name; # may also use IP address: -l 111.111.111.111
# you only need to run the cloud9.sh once after each install or update from my experience to implement the plugins.
# then after that you can run right from node or preferably forever.
node server.js -w ~/git/ -l my.host.name --username riaEvangelist --password is4MyYsOnly ;
# this will inevitably throw E_NOENT errors and crash but that can be fixed by using forever to recover from that
forever start server.js -w ~/git/ -l my.host.name --username riaEvangelist --password is4MyYsOnly;
### WTF is that doing?
# Packager needs node version 8, so we are providing it with nvm.
# "File already exists" problem, looks like breakage in one of two vfs packages,
# so we remove "~" character from package versions before npm install.
# Finally we are adding global error handler, preventing editor from crashing on few strange,
# but looking harmless exceptions.
# **All those workarounds should be discouraged, but they can fill the gap before promised next cloud9 release.**
# The -l paramater is only needed if you want to expose the cloud9 instance to the world via an IP or a hostname.
# Also username and password are optional of course.
# special thanks to this thread for helping me get started on creating this version for my install
# https://github.com/ajaxorg/cloud9/issues/2904
# > Written with [StackEdit](http://benweet.github.io/stackedit/).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment