加载net / ssh / shell时遇到问题

时间:2014-01-14 15:49:17

标签: ruby shell ssh jenkins

我有一个jenkins工作,现在只是试图运行一个简单的ruby脚本。然而,它在require' net / ssh / shell中失败了 在詹金斯,我有:

gem install net-ssh -v 2.0
gem install net-ssh-shell
gem uninstall net-ssh --version 2.1.4

在红宝石中我有

gem 'net-ssh', '=2.0.0'
require 'net/ssh'
require 'net/ssh/shell'

但是当我运行脚本时,我收到了这个错误:

Gem::LoadError: Unable to activate net-ssh-shell-0.2.0, because net-ssh-2.0.0 conflicts with net-ssh (~> 2.1.0)
  raise_if_conflicts at /usr/local/rbenv/versions/jruby-1.7.4/lib/ruby/shared/rubygems/specification.rb:1637
            activate at /usr/local/rbenv/versions/jruby-1.7.4/lib/ruby/shared/rubygems/specification.rb:746
        try_activate at /usr/local/rbenv/versions/jruby-1.7.4/lib/ruby/shared/rubygems.rb:212
             require at /usr/local/rbenv/versions/jruby-1.7.4/lib/ruby/shared/rubygems/custom_require.rb:59
             require at /usr/local/rbenv/versions/jruby-1.7.4/lib/ruby/shared/rubygems/custom_require.rb:55
              (root) at sparse_databases/refresh_sparse.rb:4

我试过不指定要安装哪个版本的net-ssh,而不是卸载2.1.4。

0 个答案:

没有答案