diff --git a/manifests/main/install.pp b/manifests/main/install.pp new file mode 100644 index 0000000..7ddb1d3 --- /dev/null +++ b/manifests/main/install.pp @@ -0,0 +1,12 @@ +## resources_cd::main::install.pp +# Module name: resources_cd +# Author: Arne Teuke (arne_teuke@confdroid.com) +# @summary Class install required packages for the resources_cd module. +############################################################################## +class resources_cd::main::install ( + +) inherits resources_cd::params { + package { $reqpackages: + ensure => $pkg_ensure, + } +} diff --git a/manifests/params.pp b/manifests/params.pp index 4ece0b9..1c94628 100644 --- a/manifests/params.pp +++ b/manifests/params.pp @@ -2,9 +2,16 @@ # Module name: resources_cd # Author: Arne Teuke (arne_teuke@confdroid.com) # @summary Class contains all parameters for the resources_cd module. +# @param [string] reqpackages which packages to install +# @param [string] pkg_ensure version to install, 'present', 'latest', 'v1.0' ############################################################################## class resources_cd::params ( + String $reqpackages = $facts['os']['name'] ? { + 'Rocky' => ['yum', 'yum-utils'], + }, + String $pkg_ensure = 'present', + ) { # includes must be last include resources_cd::main::config