Setup your application with PostgreSQL


  1. macOS
    • PostgreSQL installation as a Mac app
  2. Linux (Ubuntu)
  3. Windows





Setup DATABASE_URL in application.yml

  1. Open your config/application.yml

  2. Add the following:

    DATABASE_URL: postgresql://USERNAME:PASSWORD@localhost
  3. Replace USERNAME with your database username, PASSWORD with your database password.



Troubleshooting tests

  • While running test cases, if you get an error message postgresql connection timeout. Go to your spec/support/database_cleaner.rb file. And rename :truncation with :deletion.

Please, do not commit `databasecleaner.rb` to the repository either._