Skip to content

Instantly share code, notes, and snippets.

@mafernando
Last active July 11, 2016 22:32
Show Gist options
  • Save mafernando/f4b0863290757c09bed9342d54ad4bd9 to your computer and use it in GitHub Desktop.
Save mafernando/f4b0863290757c09bed9342d54ad4bd9 to your computer and use it in GitHub Desktop.
ubuntu_14_lts_setup.md
# sudo ntpdate ntp.ubuntu.com

sudo apt-get install linux-image-extra-$(uname -r)
sudo apt-get install apparmor

sudo apt-get update
sudo apt-get install apt-transport-https ca-certificates
sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
nano /etc/apt/sources.list.d/docker.list
    > deb https://apt.dockerproject.org/repo ubuntu-trusty main
sudo apt-get update
sudo apt-get purge lxc-docker
apt-cache policy docker-engine  

sudo apt-get update
sudo apt-get install linux-image-generic-lts-trusty
sudo reboot

sudo apt-get update
sudo apt-get install docker-engine
sudo service docker start
sudo docker run hello-world

# install compose 

sudo -i curl -L https://github.com/docker/compose/releases/download/1.6.2/docker-compose-`uname -s`-`uname -m` > /usr/local/bin/docker-compose
chmod +x /usr/local/bin/docker-compose
exit

sudo apt-get install git 
cd /tmp
git clone https://github.com/mafernando/api.git
git checkout demo/odl-bsc
@mafernando
Copy link
Author

mafernando commented Jul 6, 2016

Step 1: Update System

sudo yum update

Step 2: Install Pre-Requisites

sudo yum -y install git
sudo yum -y install gcc-c++ patch readline readline-devel zlib zlib-devel
sudo yum -y install libyaml-devel libffi-devel openssl-devel make
sudo yum -y install bzip2 autoconf automake libtool bison 
sudo yum -y install sqlite-devel libffi-devel openssl-devel
sudo yum -y install ntp

Step 3: Specify Repo & Install Postgres

sudo yum -y install https://download.postgresql.org/pub/repos/yum/9.4/redhat/rhel-7-x86_64/pgdg-redhat94-9.4-2.noarch.rpm
sudo rpm -Uvh http://yum.postgresql.org/9.4/redhat/rhel-7-x86_64/pgdg-redhat94-9.4-1.noarch.rpm

sudo yum -y install postgresql94-server
sudo yum -y install postgresql94-devel
sudo yum -y install postgresql94-contrib

Step 4: Create & Switch to Jellyfish User

sudo useradd jellyfish
sudo su - jellyfish

Step 5: Install rbenv - https://github.com/rbenv/rbenv#installation

git clone https://github.com/rbenv/rbenv.git ~/.rbenv
cd ~/.rbenv && src/configure && make -C src
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bash_profile
source ~/.bash_profile 
~/.rbenv/bin/rbenv init
eval "$(rbenv init -)"
type rbenv

Step 6: Install ruby-build

git clone https://github.com/rbenv/ruby-build.git ~/.rbenv/plugins/ruby-build

Step 7: Clone Jellyfish from GitHub

cd /tmp/jellyfish
git clone https://github.com/boozallen/projectjellyfish.git
git clone https://github.com/mafernando/api.git

Step 8: Install Ruby

# https://rafpe.ninja/2016/03/25/docker-compose-error-while-loading-shared-libraries-libz-so-1/
sudo mount /tmp -o remount,exec

rbenv install "$(cat /tmp/projectjellyfish/.ruby-version)"
rbenv global "$(cat /tmp/projectjellyfish/.ruby-version)"
rbenv install "$(cat /tmp/api/.ruby-version)"
rbenv global "$(cat /tmp/api/.ruby-version)"

Step 9: Install Bundler

gem install bundler

Step 10: Install pg Gem

gem install pg -v '0.18.3' -- --with-pg-config=/usr/pgsql-9.4/bin/pg_config

Step 11: Install Gems & Build UX

bundle install

Step #: X

x

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment