Skip to content

Instantly share code, notes, and snippets.



Last active Dec 15, 2017
What would you like to do?
# Ubuntu setup from vagrant
###### via
echo "Packages setting..."
sudo apt-get -y update
sudo apt-get -y 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
## Ruby
echo "Ruby setting..."
git clone git:// .rbenv
git clone git:// ~/.rbenv/plugins/ruby-build
git clone ~/.rbenv/plugins/rbenv-gem-rehash
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bashrc
echo 'eval "$(rbenv init -)"' >> ~/.bashrc
echo 'export PATH="$HOME/.rbenv/plugins/ruby-build/bin:$PATH"' >> ~/.bashrc
echo 'gem: --no-ri --no-rdoc' > ~/.gemrc
~/.rbenv/bin/rbenv install 2.2.3
~/.rbenv/bin/rbenv global 2.2.3
~/.rbenv/versions/2.2.3/bin/gem install bundler
## Nodejs
echo "Nodejs setting..."
sudo add-apt-repository -y ppa:chris-lea/node.js
sudo apt-get -y update
sudo apt-get -y install nodejs
## PostgreSQL
echo "PostgreSQL setting..."
sudo sh -c "echo 'deb precise-pgdg main' > /etc/apt/sources.list.d/pgdg.list"
wget --quiet -O - | sudo apt-key add -
sudo apt-get -y update
sudo apt-get -y install postgresql-common
sudo apt-get -y install postgresql-9.3 libpq-dev
sudo -u postgres createuser vagrant -s
sudo -u postgres psql << END_OF_INPUT
\password vagrant
## Redis
echo "Redis setting..."
sudo apt-get -y install tcl8.5
tar xzf redis-stable.tar.gz
cd redis-stable
make test
sudo make install
cd utils
sudo ./
## Rails
echo "Rails presetting..."
sudo chown -R vagrant:vagrant /usr/local/src/bundles
echo "Setup finished."
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.