- From: <
>
- To:
- Subject: [chef] chef_gem installing with wrong rubygems
- Date: Wed, 6 Feb 2013 14:08:04 -0800 (PST)
I just upgraded from running 0.10.8 with ruby 1.8.7 installed on the system to
the omnibus 10.18.2. I have a recipe running chef_gem to install a gem and
chef
can see that the gem is not in the omnibus rubygems, so it installs it. But it
installs it into the system rubygems. Even if I run chef-client again it sees
the gem is not in omnibus and then installs it in the system. If I remove
/usr/bin/gem then chef will install it inside omnibus. I thought chef_gem was
supposed to ignore /usr/bin/gem. Has anyone seen this, or know how to work
around it, or know what I may be doing wrong?
I'm running Centos 5.4 as root with
PATH=/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin
[root]# gem list netaddr
*** LOCAL GEMS ***
[root]# /opt/chef/embedded/bin/gem list netaddr
*** LOCAL GEMS ***
[root]# chef-client -l debug
...
[2013-02-06T21:01:41+00:00] INFO: Processing chef_gem[netaddr] action install
(cookbook::recipe line 2)
[2013-02-06T21:01:41+00:00] DEBUG: chef_gem[netaddr] detected omnibus
installation in /opt/chef/embedded/bin
[2013-02-06T21:01:41+00:00] DEBUG: chef_gem[netaddr] using gem from running
ruby environment
[2013-02-06T21:01:41+00:00] DEBUG: chef_gem[netaddr] no installed version
found
for netaddr (>= 0)
[2013-02-06T21:01:43+00:00] DEBUG: found gem netaddr version 1.5.0 for
platform ruby from
http://rubygems.org/
Successfully installed netaddr-1.5.0
1 gem installed
...
[root]# gem list netaddr
*** LOCAL GEMS ***
netaddr (1.5.0)
[root]# /opt/chef/embedded/bin/gem list netaddr
*** LOCAL GEMS ***
[root]#
Thanks,
Dan
- [chef] chef_gem installing with wrong rubygems, dan, 02/06/2013
Archive powered by MHonArc 2.6.16.