Puppet Function: requires_os
- Defined in:
- puppet/modules/wmflib/lib/puppet/parser/functions/requires_os.rb
- Function type:
- Ruby 3.x API
Overview
17 18 19 20 21 |
# File 'puppet/modules/wmflib/lib/puppet/parser/functions/requires_os.rb', line 17 newfunction(:requires_os, :arity => 1) do |args| Puppet::Parser::Functions.function(:os_version) fail(ArgumentError, 'requires_os(): string argument required') unless args.first.is_a?(String) fail(Puppet::ParseError, "OS #{args.first} required.") unless function_os_version(args) end |