X-Git-Url: https://git.adam-barratt.org.uk/?p=mirror%2Fdsa-puppet.git;a=blobdiff_plain;f=3rdparty%2Fmodules%2Fstdlib%2Flib%2Fpuppet%2Fparser%2Ffunctions%2Fensure_resources.rb;h=c7032caa2dad05c1792a255d2c16921af8985bd2;hp=642247c9c3cc2c8ddcfd94e69ef262d1f0f8ee49;hb=30caaa85aed7015ca0d77216bff175eebd917eb7;hpb=6f656bd4265e3dab13b9af2bf96e9044322e9d8f diff --git a/3rdparty/modules/stdlib/lib/puppet/parser/functions/ensure_resources.rb b/3rdparty/modules/stdlib/lib/puppet/parser/functions/ensure_resources.rb index 642247c9c..c7032caa2 100644 --- a/3rdparty/modules/stdlib/lib/puppet/parser/functions/ensure_resources.rb +++ b/3rdparty/modules/stdlib/lib/puppet/parser/functions/ensure_resources.rb @@ -2,10 +2,16 @@ require 'puppet/parser/functions' Puppet::Parser::Functions.newfunction(:ensure_resources, :type => :statement, - :doc => <<-'DOC' + :doc => <<-DOC + @summary Takes a resource type, title (only hash), and a list of attributes that describe a resource. + @return + created resources with the passed type and attributes + + @example Example usage + user { 'dan': gid => 'mygroup', ensure => present, @@ -14,7 +20,7 @@ Puppet::Parser::Functions.newfunction(:ensure_resources, An hash of resources should be passed in and each will be created with the type and parameters specified if it doesn't already exist. - ensure_resources('user', {'dan' => { gid => 'mygroup', uid => '600' } , 'alex' => { gid => 'mygroup' }}, {'ensure' => 'present'}) + ensure_resources('user', {'dan' => { gid => 'mygroup', uid => '600' }, 'alex' => { gid => 'mygroup' }}, {'ensure' => 'present'}) From Hiera Backend: