Application Setup

Application Setup

Followig are the steps to set up the application on the system:

  1. Fork or clone the PLTcode directory from https://github.com/systers/language-translation
  2. Enter the application’s root directory.
  3. Run the following commands:

$ rake db:migrate $ rake db:seed $ bower install $ rails s

  1. Enter localhost:3000 on a web browser

Problem during setup

  1. Cannot load rails.application.database_configuration (runtime error)
  2. Problem in ruby version
  3. Same email registration problem while run the rake db:seed
  4. Problem during bower install command

Solutions:

  1. Database configuration error
  • Move the config/database.yml.example to config/database.yml and change the settings like host, username and password accordingly.
  1. ruby version
  • Set the version of the ruby in this file language-translation/.ruby-version
  1. problem arise when run the rake db:seed

Following are the commands that are used to solve the problem:

  • rake db:drop
  • rake db:create
  • rake db:schema:load (think of this as running all the migrations you’ve run before)
  • rake db:seed (creates your 100 database users)
  1. Missing bootstrap files
  • $ run the bower install command or $ bundle exec bower install
Written on May 31, 2016