class Puppet::Settings::AutosignSetting

A specialization of the file setting to allow boolean values.

The autosign value can be either a boolean or a file path, and if the setting is a file path then it may have a owner/group/mode specified.

@api private

Public Instance Methods

munge(value) click to toggle source
   # File lib/puppet/settings/autosign_setting.rb
11 def munge(value)
12   if ['true', true].include? value
13     true
14   elsif ['false', false, nil].include? value
15     false
16   elsif Puppet::Util.absolute_path?(value)
17     value
18   else
19     raise Puppet::Settings::ValidationError, _("Invalid autosign value %{value}: must be 'true'/'false' or an absolute path") % { value: value }
20   end
21 end