Issue #18205 has been updated by Jesse Endahl.

Unfortunately I'm still unclear on why it's happening, but I wanted to say that 
I've run into this as well, only on certain machines. OS version and machine 
model don't seem to matter. Not sure what the common thread is yet. My 
workaround (until I have more time to figure out what's causing it) was to add 
this hacky goodness to my puppet boostrapping preinstall script:

<code>

    thetime=`date +%Y-%m-%d--%H%M%S`
    rubydir="/usr/lib/ruby"

    echo "Making sure the ruby dir is symlinked correctly..."

        if [ -L "${rubydir}" ]; then
      echo "Ruby dir is symlinked correctly"
                else
                        if [[ -d "${rubydir}" && ! -L "${rubydir}" ]] ; then
                        echo "It's a directory. Ruby dir is not symlinked. 
Backing up existing directory and creating symlink to 
/System/Library/Frameworks/Ruby.framework/Versions/Current/usr/lib/ruby"
                        mv /usr/lib/ruby /usr/lib/ruby-${thetime}
                        ln -s 
/System/Library/Frameworks/Ruby.framework/Versions/Current/usr/lib/ruby 
/usr/lib/ruby
                        fi
        fi

</code>

----------------------------------------
Bug #18205: Ruby libraries are broken under osx mountain lion
https://projects.puppetlabs.com/issues/18205#change-88045

* Author: Ben Ford
* Status: Closed
* Priority: Normal
* Assignee: 
* Category: 
* Target version: 
* Affected Puppet version: 2.7.20
* Keywords: 
* Branch: 
----------------------------------------
See 
https://ask.puppetlabs.com/question/67/unable-to-run-puppet-on-osx-mountain-lion/

Puppet opensource cannot require libraries because the rubylib has apparently 
changed. Any puppet scripts exit with:
`/usr/bin/puppet:3:in `require': no such file to load -- 
puppet/util/command_line (LoadError)
from /usr/bin/puppet:3`

As a hacky workaround, I made symlinks, like

    sudo ln -s /usr/lib/ruby/site_ruby/1.8/puppet 
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/site_ruby/1.8/puppet
    sudo ln -s /usr/lib/ruby/site_ruby/1.8/puppet.rb 
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/site_ruby/1.8/puppet.rb
    sudo ln -s /usr/lib/ruby/site_ruby/1.8/semver.rb 
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/site_ruby/1.8/semver.rb





-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://projects.puppetlabs.com/my/account

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/puppet-bugs?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to