3
votes

when i run my rails application in production mode images are not displayed and css is not working in my console i got the message ActionController::RoutingError (No route matches "/stylesheets/theme.css"): Rendered C:/Ruby192/lib/ruby/gems/1.9.1/gems/actionpack-3.0.3/lib/action_dispatch/middleware/templates/rescues/routing_error.erb within rescues/layout (0.0ms) but in my view/layout application.html.erb i included the line <%= stylesheet_link_tag 'theme' %> and theme.css is present in the public/stylesheet folder

1

1 Answers

5
votes

make the following change in config/production.rb

change:

config.serve_static_assets = false

to:

config.serve_static_assets = true

That will fix it, I guarantee