From: Hunter Haugen Date: Thu, 17 Mar 2016 16:25:38 +0000 (-0700) Subject: Merge pull request #576 from yadavnikhil/master X-Git-Url: https://gitweb.fluxo.info/?a=commitdiff_plain;h=b6383d259cf4917edd832ba31cf4dae2b4201235;p=puppet-stdlib.git Merge pull request #576 from yadavnikhil/master ensure_packages.rb: Modifed to pass hiera parameters (as hash,array) as first argument --- b6383d259cf4917edd832ba31cf4dae2b4201235 diff --cc README.markdown index c9bbdad,b6ead96..e346f4f --- a/README.markdown +++ b/README.markdown @@@ -344,14 -344,17 +344,22 @@@ Converts the case of a string or of al Returns true if the argument is an array or hash that contains no elements, or an empty string. Returns false when the argument is a numerical value. *Type*: rvalue. +#### `enclose_ipv6` + +Takes an array of ip addresses and encloses the ipv6 addresses with square +brackets. *Type*: rvalue. + #### `ensure_packages` - Takes a list of packages and only installs them if they don't already exist. It optionally takes a hash as a second parameter to be passed as the third argument to the `ensure_resource()` function. *Type*: statement. + Takes a list of packages array/hash and only installs them if they don't already exist. It optionally takes a hash as a second parameter to be passed as the third argument to the `ensure_resource()` or `ensure_resources()` function. *Type*: statement. + + For Array: + + ensure_packages(['ksh','openssl'], {'ensure' => 'present'}) + + For Hash: + + ensure_packages({'ksh' => { enure => '20120801-1' } , 'mypackage' => { source => '/tmp/myrpm-1.0.0.x86_64.rpm', provider => "rpm" }}, {'ensure' => 'present'}) #### `ensure_resource`