我的故事 http://mystory.cc/ 多人博客系统,源代码在: https://github.com/gazeldx/mystory/
rails3.2.7 升到 Rails3.2.11, 改动如下: Gemfile:
gem 'rails', '3.2.11' gem 'sass-rails', '~> 3.2.3'# Sass adapter for the Rails asset pipeline. group :assets do gem 'coffee-rails', '~> 3.2.1'# Coffee Script adapter for the Rails asset pipeline. gem 'uglifier', '>= 1.0.3'# Ruby wrapper for UglifyJS JavaScript compressor end
config/environments/production.log 去掉:config.assets.css_compressor = :scss 如果不去,报错:
ActionView::Template::Error (uninitialized constant Sass::Rails::Compressor (in /root/mystory/app/assets/stylesheets/user.css)): Removing config.assets.css_compressor from your config (this is handled internally by sass-rails) solves the issue. Refer: https://github.com/rails/sass-rails/issues/111
后来 unicorn 启动报错:
/usr/local/rvm/gems/ruby-1.9.3-p0@global/gems/bundler-1.0.22/lib/bundler/spec_set.rb:88:in block in materialize': Could not find rake-10.0.3 in any of the sources (Bundler::GemNotFound)
from /usr/local/rvm/gems/ruby-1.9.3-p0@global/gems/bundler-1.0.22/lib/bundler/spec_set.rb:82:in
map!'
就把 RVM 也升级了下
$ rvm get stable 装了最新的 Ruby1.9.3-p385, 然后参考https://github.com/gazeldx/mystory/wiki/Nginx 把 Ngnix 和 RVM 配置好,一个小时,升级完成!