-
-
Save vincentlkl/d05c5b1a8bc384582a4a to your computer and use it in GitHub Desktop.
This file contains 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, upgrade and install development tools: | |
sudo apt-get update | |
sudo apt-get install git-core curl zlib1g-dev build-essential libssl-dev libreadline-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt1-dev libcurl4-openssl-dev python-software-properties libffi-dev nodejs | |
# Install rbenv | |
cd | |
git clone https://github.com/rbenv/rbenv.git ~/.rbenv | |
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bashrc | |
echo 'eval "$(rbenv init -)"' >> ~/.bashrc | |
exec $SHELL | |
git clone https://github.com/rbenv/ruby-build.git ~/.rbenv/plugins/ruby-build | |
echo 'export PATH="$HOME/.rbenv/plugins/ruby-build/bin:$PATH"' >> ~/.bashrc | |
exec $SHELL | |
rbenv install 2.3.0 | |
rbenv global 2.3.0 | |
ruby -v | |
# Install bundler: | |
gem install bundler | |
# Rehash: | |
rbenv rehash | |
# Install Phusion's PGP key to verify packages | |
gpg --keyserver keyserver.ubuntu.com --recv-keys 561F9B9CAC40B2F7 | |
gpg --armor --export 561F9B9CAC40B2F7 | sudo apt-key add - | |
# Add HTTPS support to APT | |
sudo apt-get install apt-transport-https | |
# Add the passenger repository | |
sudo sh -c "echo 'deb https://oss-binaries.phusionpassenger.com/apt/passenger trusty main' >> /etc/apt/sources.list.d/passenger.list" | |
sudo chown root: /etc/apt/sources.list.d/passenger.list | |
sudo chmod 600 /etc/apt/sources.list.d/passenger.list | |
sudo apt-get update | |
# Install nginx and passenger | |
sudo apt-get install nginx-full passenger | |
# Restart nginx: | |
sudo service nginx start | |
# installing postgresql | |
sudo apt-get install postgresql postgresql-contrib libpq-dev |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment