Heroku does NOT compile files under assets pipelines in Rails 4

Heroku's asset plugins no longer work since Rails 4 does not support plugins. You need to use Heroku's asset gems instead. Place this in your Gemfile:

group :production do
  gem 'rails_log_stdout',           github: 'heroku/rails_log_stdout'
  gem 'rails3_serve_static_assets', github: 'heroku/rails3_serve_static_assets'
end

Follow Heroku's guide on getting started with Rails 4.

Update (07/22/2013): Heroku now supplies a different gem to precompile assets.

group :production do
  gem 'rails_12factor'
end

You need to config Rails to serve static assets in production: config/environments/production.rb

SampleApp::Application.configure do
  .
  .
  .
  config.serve_static_assets = true
  .
  .
  .
end

UPDATE:

In Rails 4 is deprecated, and has been changed by:

config.serve_static_files = true 

Since rails 4 replaced manifest.yml with manifest-(fingerprint).json, you'll want to enable static asset serving.

From Getting Started with Rails 4.x on Heroku:

gem 'rails_12factor', group: :production

then

bundle install

and, finally,

git push heroku

Fixed the issue for me. Hope this helps!


I run exactly into the same problem.

I set config.serve_static_assets = true in my environments/production.rb file until heroku wont't support the new manifest format.

So it is a temporal solution until heroku support will be added.