RailsApps/rails3-mongoid-omniauth — Issue #11: can't push to Heroku -- ideas?
Author: FreeAssoc
Created: 2012-01-03 04:52:47+00:00
State: open

Hello - I followed the instructions in this tutorial and the app runs fine locally on my machine, but when I try to push to Heroku (using the instructions at http://railsapps.github.com/rails-heroku-tutorial.html) I get the following error each time I try to push, and rerunning bundle install doesn't seem to help. Any ideas?

(app name changed to 'MyHerokuApp' here)

➜ MyHerokuApp git:(master) git push heroku master
Counting objects: 100, done.
Delta compression using up to 8 threads.
Compressing objects: 100% (84/84), done.
Writing objects: 100% (100/100), 73.53 KiB, done.
Total 100 (delta 10), reused 0 (delta 0)

-----> Heroku receiving push
-----> Ruby/Rails app detected
-----> Installing dependencies using Bundler version 1.1.rc.7
Running: bundle install --without development:test --path vendor/bundle --binstubs bin/ --deployment
You are trying to install in deployment mode after changing
your Gemfile. Run `bundle install` elsewhere and add the
updated Gemfile.lock to version control.
You have added to the Gemfile:
* therubyracer (>= 0.9.8)
* libnotify
* rb-inotify
You have deleted from the Gemfile:
* growl
* rb-fsevent
!
! Failed to install gems via Bundler.
!
! Heroku push rejected, failed to compile Ruby/rails app

To git@heroku.com:MyHerokuApp.git
! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'git@heroku.com:MyHerokuApp.git'

'heroku logs' doesn't show me anything useful afterwards, either:

➜ FreeAssoc git:(master) heroku logs
2012-01-03T04:27:12+00:00 heroku[api]: Add-on add logging:basic by michael@freeassoc.net
2012-01-03T04:27:12+00:00 heroku[api]: Release v3 created by michael@freeassoc.net

Locally, the app runs normally when I use WEBrick (via 'rails server'), but when I start using 'thin' (the recommended webserver for Heroku hosting) by using

$bundle exec thin -e production start

I get an error (like it is trying to use ActiveRecord, or cannot connect to my local MongoDB instance or something)

TypeError in Home#index

Showing /Users/michael/projects/FreeAssoc/app/views/home/index.html.haml where line #2 raised:

db_name must be a string or symbol
Extracted source (around line #2):

1: %h3 Home
2: - @users.each do |user|
3: %p User: #{link_to user.name, user}

any ideas welcome - thanks, Michael