I've been using on my server Redmine 1.1.x for some time and I'm trying to upgrade it to 2.2.2. I followed the upgrade sequence and now the application is not working anymore :
我一直在用我的服务器Redmine 1.1。x有一段时间了,我试着把它升级到2.2.2。我跟踪了升级序列,现在应用程序不再工作了:
'block in materialize': Could not find builder-3.0.0 in any of the sources (Bundler::GemNotFound)
'block in materialize':在任何资料中都找不到build -3.0.0 (Bundler: GemNotFound)
However:
然而:
bicou@ssh:~/redmine-2.2.2$ bundle install
Using rake (10.0.3)
Using i18n (0.6.1)
Using multi_json (1.5.0)
Using activesupport (3.2.11)
Using builder (3.0.0)
Using activemodel (3.2.11)
Using erubis (2.7.0)
Using journey (1.0.4)
Using rack (1.4.4)
Using rack-cache (1.2)
Using rack-test (0.6.2)
Using hike (1.2.1)
Using tilt (1.3.3)
Using sprockets (2.2.2)
Using actionpack (3.2.11)
Using mime-types (1.19)
Using polyglot (0.3.3)
Using treetop (1.4.12)
Using mail (2.4.4)
Using actionmailer (3.2.11)
Using arel (3.0.2)
Using tzinfo (0.3.35)
Using activerecord (3.2.11)
Using activeresource (3.2.11)
Using coderay (1.0.8)
Using fastercsv (1.5.5)
Using icalendar (1.2.1)
Using rack-ssl (1.3.2)
Using json (1.7.6)
Using rdoc (3.12)
Using thor (0.16.0)
Using railties (3.2.11)
Using jquery-rails (2.0.3)
Using metaclass (0.0.1)
Using mocha (0.12.3)
Using mysql (2.8.1)
Using net-ldap (0.3.1)
Using pg (0.14.1)
Using ruby-openid (2.1.8)
Using rack-openid (1.3.1)
Using bundler (1.2.3)
Using rails (3.2.11)
Using rmagick (2.13.1)
Using shoulda (2.11.3)
Using sqlite3 (1.3.7)
Using yard (0.8.3)
Your bundle is complete! Use `bundle show [gemname]` to see where a bundled gem is installed.
bicou@ssh:~/redmine-2.2.2$ bundle show builder
/home/bicou/gems/gems/builder-3.0.0
bicou@ssh:~/redmine-2.2.2$ env | grep gem
GEM_HOME=/home/bicou/gems/
PATH=/home/bicou/gems/bin:/usr/local/bin:/usr/bin:/bin:/usr/bin/X11:/usr/games
GEM_PATH=/home/bicou/gems/
As you can see, builder v3.0.0 is installed. What gives?
可以看到,安装了builder v3.0.0。到底发生了什么事?
What I did try:
我所做的尝试:
- remove Gemfile.lock and run
bundle install
again - 删除Gemfile。再次安装并运行bundle。
- what Paulo Fidalgo advised (see below)
- 保罗·菲达戈建议(见下文)
Based on Paulo Fidalgo advice:
基于保罗·菲达哥的建议:
My Gemfile contains builder 3.0.0:
我的Gemfile包含了builder 3.0.0:
bicou@ssh:~/redmine-2.2.2$ grep builder Gemfile
gem "builder", "3.0.0"
bicou@ssh:~/redmine-2.2.2$ bundle update
Fetching gem metadata from http://rubygems.org/.........
Fetching gem metadata from http://rubygems.org/..
Using rake (10.0.3)
Using i18n (0.6.1)
Using multi_json (1.5.0)
Using activesupport (3.2.11)
Using builder (3.0.0)
Using activemodel (3.2.11)
Using erubis (2.7.0)
Using journey (1.0.4)
Using rack (1.4.4)
Using rack-cache (1.2)
Using rack-test (0.6.2)
Using hike (1.2.1)
Using tilt (1.3.3)
Using sprockets (2.2.2)
Using actionpack (3.2.11)
Using mime-types (1.19)
Using polyglot (0.3.3)
Using treetop (1.4.12)
Using mail (2.4.4)
Using actionmailer (3.2.11)
Using arel (3.0.2)
Using tzinfo (0.3.35)
Using activerecord (3.2.11)
Using activeresource (3.2.11)
Using bundler (1.2.3)
Using coderay (1.0.8)
Using fastercsv (1.5.5)
Using icalendar (1.2.1)
Using rack-ssl (1.3.2)
Using json (1.7.6)
Using rdoc (3.12)
Using thor (0.16.0)
Using railties (3.2.11)
Using jquery-rails (2.0.3)
Using metaclass (0.0.1)
Using mocha (0.12.3)
Using mysql (2.8.1)
Using net-ldap (0.3.1)
Using pg (0.14.1)
Using ruby-openid (2.1.8)
Using rack-openid (1.3.1)
Using rails (3.2.11)
Using rmagick (2.13.1)
Using shoulda (2.11.3)
Using sqlite3 (1.3.7)
Using yard (0.8.3)
Your bundle is updated! Use `bundle show [gemname]` to see where a bundled gem is installed.
bicou@ssh:~/redmine-2.2.2$
2 个解决方案
#1
2
You need to add builder to your Gemfile and then run:
您需要将构建器添加到Gemfile中,然后运行:
bundle update
包更新
#2
1
I had several issues (for example some gems compiled with a different ruby version than the runtime), but the main one was that my web host requires me to install gems into ~/gems
and hence to export GEMS_PATH = ~/gems/
!
我有几个问题(例如一些用不同的ruby版本编译的gem,而不是运行时),但是主要的问题是我的web主机需要我将gem安装到~/gem中,然后导出GEMS_PATH = ~/gems/!
That, in my public/.htaccess
, fixed the main issue:
在我的公共/。htaccess,解决了主要问题:
SetEnv GEM_PATH /home/bicou/gems/
#1
2
You need to add builder to your Gemfile and then run:
您需要将构建器添加到Gemfile中,然后运行:
bundle update
包更新
#2
1
I had several issues (for example some gems compiled with a different ruby version than the runtime), but the main one was that my web host requires me to install gems into ~/gems
and hence to export GEMS_PATH = ~/gems/
!
我有几个问题(例如一些用不同的ruby版本编译的gem,而不是运行时),但是主要的问题是我的web主机需要我将gem安装到~/gem中,然后导出GEMS_PATH = ~/gems/!
That, in my public/.htaccess
, fixed the main issue:
在我的公共/。htaccess,解决了主要问题:
SetEnv GEM_PATH /home/bicou/gems/