Last active
July 23, 2016 18:06
-
-
Save ellipsonic/378a520eaed8ac28760f to your computer and use it in GitHub Desktop.
Cloud9
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Update | |
sudo apt-get -y update | |
# Install git and curl | |
sudo apt-get -y install curl | |
sudo apt-get -y install git | |
# Clone the repo | |
git clone git://github.com/c9/core.git c9sdk | |
cd c9sdk | |
sudo scripts/install-sdk.sh | |
# Map the private IP to public IP | |
private_ip=$(hostname -i) | |
sudo iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j DNAT --to-destination $private_ip:80 | |
sudo iptables -A INPUT -p tcp --dport 80 -j ACCEPT | |
sudo node server.js -p 8080 -a : <&- & |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment