Reputation: 1321
This is my first rails app that is not an example out of a book and it's very simple. It works on my development, 10.6, machine and is using postgresql in production. My attempts to push up the master branch yields the "page doesn't exist".
OK, i used 'git push heroku convention1' which is he branch that works and I want to test.
heroku ps => web.1 idle for 252h thin -p $PORT -e $RACK_ENV -R $HER.. Seems OK?
heroku log => 2011-12-20T15:21:07+00:00 app[web.1]: Started GET "/" for 98.240.82.43 at
2011-12-20 07:21:07 -0800 2011-12-20T15:21:07+00:00 app[web.1]: 2011-12-20T15:21:07+00:00 app[web.1]: 2011-12-20T15:21:07+00:00 app[web.1]: ActionController::RoutingError (No route matches [GET] "/"): 2011-12-20T15:21:07+00:00 app[web.1]: cache: [GET /] miss 2011-12-20T15:21:07+00:00 app[web.1]: 2011-12-20T15:21:07+00:00 heroku[router]: GET vitae1.heroku.com/ dyno=web.1 queue=0 wait=0ms service=50ms status=404 bytes=728 2011-12-20T15:21:07+00:00 heroku[nginx]: 98.240.82.43 - - [20/Dec/2011:07:21:07 -0800] "GET / HTTP/1.1" 404 728 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_6_8) AppleWebKit/534.52.7 (KHTML, like Gecko) Version/5.1.2 Safari/534.52.7" vitae1.heroku.com 2011-12-20T15:21:07+00:00 heroku[router]: GET vitae1.heroku.com/favicon.ico dyno=web.1 queue=0 wait=0ms service=2ms status=200 bytes=0 2011-12-20T15:21:07+00:00 heroku[nginx]: 98.240.82.43 - - [20/Dec/2011:07:21:07 -0800] "GET /favicon.ico HTTP/1.1" 200 0 "http://vitae1.heroku.com/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_6_8) Apple WebKit/534.52.7 (KHTML, like Gecko) Version/5.1.2 Safari/534.52.7" vitae1.heroku.com
Looking around similar threads on stackoverflow, answers were that some other file was not found, but it appears that heroku cannot find my app and its route file: Here's the related snippet from that routes.rb:
root :to => 'openings#index' match '/openings/admin', :to => 'openings#admin' match '/openings/show_report', :to => 'openings#show_report' resources :openings
This works in production environment on my machine. What obvious thing am I overlooking? Did I miss something in pushing to heroku? There is a routes.rb file in my config folder. thanx, sam
Upvotes: 3
Views: 404
Reputation: 37507
you have to push like
git push heroku convention1:master
when you want to deploy a branch to heroku other than master. Heroku only deploys the master branch so you have to push your convention1 branch into the master branch on Heroku.
Upvotes: 2