The problem with this app is that is WIP, so we are not using anything to deploy it to our production server, we just clone it from github and we are doing a git pull every time we have something done, rake assets:precompile task takes more than 30 minutes to finish!, WTF?.
We are doing this:
$ bundle exec rake assets:clean
$ bundle exec rake assets:precompile
Our production server:
- ruby 1.9.3p194 (rbenv)
- rails 3.2.3
- unicorn
- nginx
Our rails + unicorn + rbenv + init.d daemon configuration is here: https://gist.github.com/2776085
Now, here’s our assets manifests, Gemfile and our production.rb files: http://pastie.org/3958070
So, somebody knows why this takes so long? or there’s a way to speed up assets compilation in production?.
Thank you.
UPDATE: Assets compilation times locally: http://pastie.org/3961734
Rails’s asset pipeline looks a little bit further than app/assets/{javascripts,stylesheets}.
As mentioned in the guides, there are also other locations where you can put your application’s assets:
I suggest you to read the complete guide on Rails’s asset pipeline to get more information about all this and also some tips for your production environment, such as nginx rules for caching, speeding up the assets pre-compilation, etc.