Skip to content

keyboard-nipple/driverse

Repository files navigation

431-accessible-uber Build Status

Setup

Before starting, make sure that Ruby, Rails, and SQLite3 are installed.

Clone the repository:

git clone https://github.com/keyboard-nipple/driverse.git
cd driverse

Install missing gems:

bundle install

If you get the following error,

An error occurred while installing pg (0.21.0), and Bundler cannot continue.
Make sure that `gem install pg -v '0.21.0' --source 'https://rubygems.org/'` succeeds before bundling.

Run this to install the missing dependencies for PostgreSQL:

sudo apt-get update
sudo apt-get install libpq-dev

Migrate the database:

rake db:migrate

Run the server:

rails server

Google Sign-In

For Google sign-in to work, you must first create your own Google API Console project and client ID. A guide to do so can be found here: https://developers.google.com/identity/sign-in/web/sign-in.

Once you have created a project, you have to set the environment variables in your development environment so that the application knows where to redirect the sign-in to. There are two variables that you need to set, and there are two methods to set them.

This sets the environment variables temporarily for only your current shell session.

GOOGLE_CLIENT_ID="YOUR CLIENT ID HERE"
GOOGLE_CLIENT_SECRET="YOUR SECRET HERE"

To add it permanently, add these lines to your .bashrc

export GOOGLE_CLIENT_ID="YOUR CLIENT ID HERE"
export GOOGLE_CLIENT_SECRET="YOUR SECRET HERE"

Then reload the .bashrc file:

source .bashrc

You may have to perform additional configuration in the Google API Console to add the authorized URIs and redirect URIs. The redirect URI will likely be something similar to this format:

https://[YOUR EC2/CLOUD9 INSTANCE NAME].vfs.cloud9.us-east-1.amazonaws.com/auth/google_oauth2/callback

You will need to do this for every development environment you plan to work with.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published