Puppet Function: validate_ensure
- Defined in:
- puppet/modules/wmflib/lib/puppet/parser/functions/validate_ensure.rb
- Function type:
- Ruby 3.x API
Overview
11 12 13 14 15 |
# File 'puppet/modules/wmflib/lib/puppet/parser/functions/validate_ensure.rb', line 11 newfunction(:validate_ensure, :arity => 1) do |args| unless %w(present absent).include?(args.first) fail(Puppet::ParseError, "$ensure must be \"present\" or \"absent\" (got: #{args.first.inspect}).") end end |