docker容器中:
gem source --add https://ruby.taobao.org/ --remove https://rubygems.org/
bundle install
要求安装11.2.2的rake
gem install rake -v 11.2.2
cd plugins/redmine_webhook
rake redmine:plugins:migrate RAILS_ENV=production
报错:
rake aborted!
Gem::LoadError: You have already activated rake 11.2.2, but your Gemfile requires rake 11.3.0. Prepending `bundle exec` to your command may solve this.
/var/lib/gems/2.1.0/gems/bundler-1.12.5/lib/bundler/runtime.rb:35:in `block in setup'
/var/lib/gems/2.1.0/gems/bundler-1.12.5/lib/bundler/runtime.rb:20:in `map'
/var/lib/gems/2.1.0/gems/bundler-1.12.5/lib/bundler/runtime.rb:20:in `setup'
/var/lib/gems/2.1.0/gems/bundler-1.12.5/lib/bundler.rb:95:in `setup'
/var/lib/gems/2.1.0/gems/bundler-1.12.5/lib/bundler/setup.rb:9:in `<top (required)>'
/home/redmine/redmine/config/boot.rb:4:in `<top (required)>'
/home/redmine/redmine/config/application.rb:1:in `<top (required)>'
/home/redmine/redmine/Rakefile:5:in `<top (required)>'
LoadError: cannot load such file -- bundler/setup
/home/redmine/redmine/config/boot.rb:4:in `<top (required)>'
/home/redmine/redmine/config/application.rb:1:in `<top (required)>'
/home/redmine/redmine/Rakefile:5:in `<top (required)>'
(See full trace by running task with --trace)
使用方法:
bundle exec rake redmine:plugins:migrate RAILS_ENV=production
解决
来源:oschina
链接:https://my.oschina.net/u/259976/blog/753851