Skip to content
Luke Baker edited this page Oct 31, 2019 · 14 revisions

Requirements

These are the versions of software that we are currently using so we know the code works with these version. It might work with earlier or later versions as well, but we haven't tested those.

  • git
  • ruby 1.9.3
  • rubygems 1.8.x
  • bundler 1.17.3
  • redis 2.4.X (after installation you can simply run redis-server or setup the proper startup scripts that come with redis for your operating system, so that it starts on server restart)

RedHat-based distros (CentOS, Amazon Linux, Scientific Linux, etc.)

sudo yum install -y git ruby-devel rubygem-bundler make gcc mysql-libs mysql-devel mysql libxml2-devel libxslt-devel

Step-by-step instructions for Ubuntu 16.04 (Xenial Xerus)

sudo apt-get update
sudo apt-get install -y git build-essential checkinstall git libmysqlclient-dev libxslt1-dev libxml2-dev mysql-server autoconf automake autotools-dev bison libbison-dev libffi-dev libgdbm-dev libncurses5-dev libreadline6-dev libssl-dev libssl-doc libtinfo-dev libyaml-dev m4mysql-client
git clone https://github.com/rbenv/rbenv.git ~/.rbenv
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bashrc
echo 'eval "$(rbenv init -)"' >> ~/.bashrc
source ~/.bashrc
git clone https://github.com/rbenv/ruby-build.git ~/.rbenv/plugins/ruby-build
rbenv install 1.9.3-p551
rbenv global 1.9.3-p551
gem install bundler
rbenv rehash
wget https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/redis/redis-2.4.18.tar.gz
tar zxvf redis-2.4.18.tar.gz
cd redis-2.4.18/
make
nohup ./src/redis-server &

Download code

git clone git://github.com/allourideas/pairwise-api.git

Install all the necessary gems

bundle install --path vendor/ --binstubs --local

Some gems may require that native extensions be built. These native extensions may require you to install additional libraries. I've tried to enumerate them above in the requirements.

Continue installing for the proper environment

To complete your installation, the instructions will vary depending on which environment you're setting up. If you're setting it up to serve more than a single user, you probably want to choose the production environment. Otherwise for development or testing, choose those environments.

Start Using the API

Using The API