I am fairly new with rails and ruby and heroku, and am trying to deploy an app. The deployment works, but when i try to visit the site, none of the css, or JavaScript is loading. In the log it says:
ActionController::RoutingError (No route matches [GET]
I have tried adding gem 'rails_12factor', group: :production
to my gemfile, doing assets:precompile, and a lot else, but yet the images and css still won't load. Any help would be greatly appreciated.
ruby 2.0.0
rails 4.0.0
Sounds like an asset pipeline issue. Have a look at the Heroku information for the rails asset pipeline:
https://devcenter.heroku.com/articles/rails-asset-pipeline
More than likely you'll have to precompile assets locally.
RAILS_ENV=production bundle exec rake assets:precompile
Then just push to git and Heroku.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.