ASCIIwwdc / asciiwwdc.com

Searchable full-text transcripts of WWDC sessions
https://asciiwwdc.com
MIT License
555 stars 43 forks source link

Fix so that DATABASE_URL can be read from the .env file #21

Closed natecook1000 closed 9 years ago

mattt commented 9 years ago

This is automatically populated when $ foreman start is run, and is pre-set as an environment variable when deploying to Heroku, so this shouldn't be necessary... Are you running this some other way?

natecook1000 commented 9 years ago

I was getting an error that the connection was nil when trying to build the database with bundle exec rake db:seed. Could it be my ruby version? I'm on 2.0.0p451.

mattt commented 9 years ago

Ah, you'd need to do $ foreman run bundle exec rake db:seed (a mouthful, I know).

I personally like not having that automatically defined for Rake tasks, since I actually populate the production database locally from that, passing in the DATABASE_URL from $ heroku:config

natecook1000 commented 9 years ago

Great! I'll back this out and update the README instead.

mattt commented 9 years ago

:ok_hand: :grin: