Search code examples
ruby-on-railsruby-on-rails-4herokuproductionheroku-postgres

Ruby backend doesn't work on heroku live site


On production, only my site's static pages work, and all pages with instance variables return a 404 error. For some reason, when I run heroku logs, the error does not appear in the log. Everything is fine locally.

I am not sure where this issue might originate from, so please ask in the comments!

Thanks,

Jill

Edit:

Here's the routes file

Rails.application.routes.draw do
  resources :comps do
    resources :tracks do
      member { get :download }
    end
  end

  devise_for :users
  resources :shows
  resources :contacts, only: [:index, :new, :create]

  get 'literal/noise' => 'literal#noise'

  root 'welcome#hi'

end

Solution

  • Figured it out. I never ran heroku run rake db:migrate, so heroku was look for instances of models that didn't exist yet :{