Ruby on Rails Tuesday, February 18, 2014



On Tuesday, 18 February 2014 17:08:47 UTC+1, Ganesh Ranganathan wrote:

On Tue, Feb 18, 2014 at 9:29 PM, Javix <s.ca...@gmail.com> wrote:
Run in production:

rails s -e production

There are no CSS fiound !

This is strange. This issue can occur for individual css and js files but application.css and application.js should be added by default. 

For other files you have to add config.assets.precompile += %w(filename.css).

I found the way to make it work:

add/modify the following line in environments/production.rb:

config.serve_static_assets = true
config.assets.compile = true

Then run again

$ RAILS_ENV rake assets:precompile 
$ rails s -e production

And it works. 

Any idea ?

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/44905326-48b3-4da4-9383-0396798576d8%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

No comments:

Post a Comment