Created
October 13, 2016 17:50
-
-
Save louanfontenele/79a96b828bed4e3e161c291241813a28 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
===================== | |
----RUBY ON RAILS---- | |
ENTRE NO MODO SU, É OBRIGATÓRIO!!!!! | |
======== | |
1º passo | |
======== | |
sudo apt-get update | |
======== | |
2º passo | |
======== | |
sudo apt-get install -y 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 | |
======== | |
3º passo | |
======== | |
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.1 | |
rbenv global 2.3.1 | |
ruby -v | |
======== | |
4º passo | |
======== | |
gem install bundler | |
======== | |
5º passo | |
======== | |
curl -sL https://deb.nodesource.com/setup_6.x | sudo -E bash - | |
sudo apt-get install -y nodejs | |
======== | |
6º passo | |
======== | |
gem install rails -v 5.0.0.1 | |
rbenv rehash | |
rails -v | |
======== | |
7º passo | |
======== | |
sudo apt-get install -y mysql-server mysql-client libmysqlclient-dev | |
======== | |
8º passo | |
======== | |
sudo sh -c "echo 'deb http://apt.postgresql.org/pub/repos/apt/ xenial-pgdg main' > /etc/apt/sources.list.d/pgdg.list" | |
wget --quiet -O - http://apt.postgresql.org/pub/repos/apt/ACCC4CF8.asc | sudo apt-key add - | |
sudo apt-get update | |
sudo apt-get install -y postgresql-common | |
sudo apt-get install -y postgresql-9.6 libpq-dev | |
======== | |
9º passo | |
======== | |
sudo -u postgres createuser aluno -s (if you want create a new user, if you get any error, you already have this user) | |
sudo -u postgres psql | |
\password root | |
YOURPASS | |
YOURPASS | |
\q |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment