2

I have a puppet setup containing a puppet master and couple of nodes - this works as intended.

However - on the latest node I am working on I need to install rvm/ruby+nginx/passenger. This is done using these puppet modules

maestrodev-rvm (v1.13.1) puppet-nginx (v0.6.0)

All of this is installed and working - I can do bundle install and confirm this is installed into the right gemset and if I go to a different folder i can confirm gem list is not picking up gems for this gemset.

Accessing my application also works and yields the expected results.

So far so good.. the problems starts next time puppet runs - this causes all of my gems with native extensions to break. I'm getting the error:

Message from application: incompatible library version - /usr/local/rvm/gems/ruby-2.3.1@robot/gems/http_parser.rb-0.6.0/lib/ruby_http_parser.so (LoadError)

When comparing the content of the file before/after puppet run (using md5sum) I'm getting different checksums.

It seems like I am getting some unexpected output when running

/opt/puppetlabs/puppet/bin/gem env
RubyGems Environment:
  - RUBYGEMS VERSION: 2.2.5
  - RUBY VERSION: 2.1.9 (2016-03-30 patchlevel 490) [x86_64-linux]
  - INSTALLATION DIRECTORY: /usr/local/rvm/gems/ruby-2.3.1
  - RUBY EXECUTABLE: /opt/puppetlabs/puppet/bin/ruby
  - EXECUTABLE DIRECTORY: /usr/local/rvm/gems/ruby-2.3.1/bin
  - SPEC CACHE DIRECTORY: /root/.gem/specs
  - RUBYGEMS PLATFORMS:
    - ruby
    - x86_64-linux
  - GEM PATHS:
     - /usr/local/rvm/gems/ruby-2.3.1
     - /usr/local/rvm/gems/ruby-2.3.1@global
  - GEM CONFIGURATION:
     - :update_sources => true
     - :verbose => true
     - :backtrace => false
     - :bulk_threshold => 1000
  - REMOTE SOURCES:
     - https://rubygems.org/
  - SHELL PATH:
     - /usr/local/rvm/gems/ruby-2.3.1/bin
     - /usr/local/rvm/gems/ruby-2.3.1@global/bin
     - /usr/local/rvm/rubies/ruby-2.3.1/bin
     - /usr/local/sbin
     - /usr/local/bin
     - /usr/sbin
     - /usr/bin
     - /sbin
     - /bin
     - /opt/puppetlabs/bin
     - /usr/local/rvm/bin

How come it be the GEM PATHS are pointing to the ruby-2.3.1? How can I control this value when using the ruby bundled with puppet? I was only able to find the configuration to change gem path in the puppetserver documentation.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.