puppet-puppetserver
puppet-puppetserver copied to clipboard
Add ability to configure JRUBY_JAR setting to avoid `undefined method 'keep_alive_timeout=' for #<Net::HTTP..."` errors
What are you seeing
Currently, it's not possible to use the module to configure the JRUBY_JAR
setting to use the newer 9k JRuby, meaning if you have a gem that requires Ruby > 2.1, you see errors like undefined method 'keep_alive_timeout=' for #<Net::HTTP..."
(such as https://github.com/davealden/hiera-vault/issues/5)
Affected Puppet, Ruby, OS and module versions/distributions
- Module version: Latest Commit (356e0785bcf707da001ef1e04d28b296445467f1)
Any additional information you'd like to impart
Current workaround is this quick ini_setting
code, but to keep with the rest of the module we could use augeas:
ini_setting { "Change jruby to 9k":
ensure => present,
setting => 'JRUBY_JAR',
path => "/etc/sysconfig/puppetserver",
key_val_separator => '=',
section => '',
value => '"/opt/puppetlabs/server/apps/puppetserver/jruby-9k.jar"',
show_diff => true,
notify => Class['puppetserver::service']
}