Bosh stemcell Ubuntu Ruby, in conflict with /var/vcap/bosh/lib/ruby (LoadError)

72 views Asked by At

I tried to install gist tool in Bosh VM

Synopsis The gist gem provides a gist-paste command that you can use from your terminal to upload content to https://gist.github.com/.

version

stemcells:
- name: bosh-openstack-kvm-ubuntu-trusty-go_agent
  version: 3232.2

Ubuntu package installation and release:

# apt-get install gist
# cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=14.04
DISTRIB_CODENAME=trusty
DISTRIB_DESCRIPTION="Ubuntu 14.04.4 LTS"
# dpkg -l gist
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name                                   Version                  Architecture             Description
+++-======================================-========================-========================-==================================================================================
ii  gist                                   4.2.0-1                  all                      Upload gists to gist.github.com

error message I receive

# gist-paste -p mongodb.log*
/var/vcap/bosh/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require': cannot load such file -- gist (LoadError)
        from /var/vcap/bosh/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
        from /usr/bin/gist-paste:7:in `<main>'

There is some conflict with Ubuntu provided Ruby and the one from /var/vcap/bosh/lib/ruby/site_ruby/1.9.1/rubygems. Any idea howto use the Right ruby gem?

1

There are 1 answers

0
Dan Higham On BEST ANSWER

If you run the gist-paste command as a user other than root, it should work fine. I tested this myself on stemcell 1.3232.0