Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

Ruby

Adler Hsieh
Adler Hsieh
1,823 Points

"Rake aborted!" when deploying Treebook to Heroku

The following message is what I got when deploying the treebook application after running

$git push heroku master
Running: rake assets:precompile
       DEPRECATION WARNING: Paths in SQLite3 database URLs of the form `sqlite3:///path` will be treated as absolute in Rails 4.2. Please switch to `sqlite3:dbname`. (called from <top (required)> at /tmp/build_1b216552-cf3a-44eb-85dc-e96afb04dc2a/Rakefile:6)
       rake aborted!
       Gem::LoadError: Specified 'sqlite3' for database adapter, but the gem is not loaded. Add `gem 'sqlite3'` to your Gemfile (and ensure its version is at the minimum required by ActiveRecord).

I've changed the gemfile as instructed to the following:

group :development, :test do
       gem 'sqlite3'
end

group :production do
    gem 'pg'
end

I also run the "bundle install" and changed the database.yml file as follow:

production:
  adapter: postgresql
  database: treebook
  pool: 5
  timeout: 5000

However all these do not work, and I get the error message repeatedly. I'll appreciate if anyone can solve this problem. Thanks.

I got the same error. From your notes, it sounds like you might have already tried this, but I followed the instructions here and it worked for me: http://www.jackiejohnston.us/blog/switching-to-postgresql-production-database-for-heroku-deployment/

You also want to setup postgres on your computer (I used brew) and commit the changes in git.