0
votes

I am testing a Rails 4 app in production mode, on my development server. I use the command 'RAILS_ENV=production bundle exec rake assets:precompile', which completes with no errors reported.

I then run the WEBrick server with "RAILS_ENV=production rails server"

The app seems to run normally, but my log file shows the following fatal error

ActionController::RoutingError (No route matches [GET] "/assets/application-078fb9638cc0bc92bfa6c68332887622.js")

This must have something to do with the asset file signatures, but, how can I get rid of it?

1

1 Answers

1
votes

It would appear that, by default, the property 'serve_static_assets' is not set in production.rb, which results in error messages in the server log. By setting the property to 'true', the precompilation produces the signature files referenced by the view code, eliminating the error message. This was observed using Rails 4.0.3