| One thing that I missed prior to merging the PR, is that settings adds a section to its searchpath based on the run mode. This is what enables puppetserver running in :master run mode to load settings from the [master] section. As a result of the switch to :server run mode, then applications like puppet lookup will no longer read settings from [:master]. So I think we need to add logic to https://github.com/puppetlabs/puppet/blob/e06b87a71b09e7598182c9753f6151bd4155e659/lib/puppet/settings.rb#L833 such that if run_mode is :server or :master, then we add sections for both, in that order, so that :server takes precedence over :master. One way to test is to run puppet config set environment_timeout unlimited --section master and then run the following script:
require 'puppet' |
Puppet.initialize_settings |
app = Puppet::Application[:lookup] |
puts Puppet.run_mode.inspect |
puts Puppet[:environment_timeout]
|
It should print that it's using the :server run mode and that the timeout is Infinity. I'm not sure if you want to fix this in this ticket or create a new one. |