Last active
April 8, 2017 22:26
-
-
Save luizpicolo/8876c1b6a1a7187d3f71 to your computer and use it in GitHub Desktop.
Install Server
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
# Configure Timezone | |
dpkg-reconfigure tzdata | |
# Configure locale | |
locale-gen pt_BR pt_BR.UTF-8 | |
locale-gen en_US en_US.UTF-8 | |
# Instalar Postgree e trocar senha | |
sudo apt-get install postgresql postgresql-contrib | |
psql -c "ALTER USER postgres WITH PASSWORD 'nova_senha'" -d template1 | |
# -s -> SuperUser | |
# -r Add Role | |
# -d Create Database | |
createuser -s -r postgres | |
# sudo pg_createcluster 9.3 main --start | |
# rvm rvmrc warning ignore all.rvmrcs | |
nano ~/.bashrc | |
unset rvm_path | |
unset GEM_HOME | |
# COnfigurar server Ruby | |
sudo apt-get install libcurl4-openssl-dev -y && | |
sudo apt-get install ruby-dev zlib1g-dev liblzma-dev && | |
sudo apt-get install libxslt-dev libxml2-dev -y && | |
sudo apt-get install libmysqlclient-dev -y && | |
gpg2 --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 && | |
\curl -sSL https://get.rvm.io | bash -s stable && | |
source ~/.rvm/scripts/rvm && | |
rvm requirements && | |
rvmsudo /usr/bin/apt-get install build-essential openssl libreadline6 libreadline6-dev curl git-core zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt-dev autoconf libc6-dev ncurses-dev automake libtool bison subversion && | |
rvm install ruby && | |
rvm use ruby --default && | |
rvm rubygems current && | |
gem install passenger && | |
sudo apt-get install libpq-dev && | |
rvmsudo passenger-install-nginx-module && | |
sudo update-rc.d nginx defaults | |
echo "gem: --no-ri --no-rdoc" > ~/.gemrc | |
# Links para instalação do ElastiSearch via ppa | |
# https://www.elastic.co/guide/en/elasticsearch/reference/current/setup-repositories.html | |
# Install elastic search | |
sudo update-rc.d elasticsearch defaults 95 10 | |
sudo /etc/init.d/elasticsearch start |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment