diff --git a/README.md b/README.md index 0d54a29..31dd13b 100644 --- a/README.md +++ b/README.md @@ -58,7 +58,7 @@ via site.pp or nodes.pp ```bash node 'example.example.net' { - include confdroid_chrony + include confdroid_ntp } ``` diff --git a/manifests/main/dirs.pp b/manifests/main/dirs.pp new file mode 100644 index 0000000..0920f11 --- /dev/null +++ b/manifests/main/dirs.pp @@ -0,0 +1,10 @@ +#### confdroid_ntp::main::dirs.pp +# Module name: confdroid_ntp +# Author: 12ww1160 (12ww1160@confdroid.com) +# @summary Class manages directories for the confdroid_ntp module +############################################################################### +class confdroid_ntp::main::dirs ( + +) inherits confdroid_ntp::params { + require confdroid_ntp::main::install +} diff --git a/manifests/main/files.pp b/manifests/main/files.pp new file mode 100644 index 0000000..8696a7a --- /dev/null +++ b/manifests/main/files.pp @@ -0,0 +1,10 @@ +#### confdroid_ntp::main::files.pp +# Module name: confdroid_ntp +# Author: 12ww1160 (12ww1160@confdroid.com) +# @summary Class manages files for the confdroid_ntp module +############################################################################### +class confdroid_ntp::main::files ( + +) inherits confdroid_ntp::params { + require confdroid_ntp::main::dirs +} diff --git a/manifests/main/install.pp b/manifests/main/install.pp new file mode 100644 index 0000000..cb0a6cd --- /dev/null +++ b/manifests/main/install.pp @@ -0,0 +1,12 @@ +#### confdroid_ntp::main::install.pp +# Module name: confdroid_ntp +# Author: 12ww1160 (12ww1160@confdroid.com) +# @summary Class manages installation for the confdroid_ntp module +############################################################################### +class confdroid_ntp::main::install ( + +) inherits confdroid_ntp::params { + package { $cy_reqpackages: + ensure => $cy_pkg_ensure, + } +} diff --git a/manifests/main/service.pp b/manifests/main/service.pp new file mode 100644 index 0000000..52c9f79 --- /dev/null +++ b/manifests/main/service.pp @@ -0,0 +1,10 @@ +#### confdroid_ntp::main::service.pp +# Module name: confdroid_ntp +# Author: 12ww1160 (12ww1160@confdroid.com) +# @summary Class manages services for the confdroid_ntp module +############################################################################### +class confdroid_ntp::main::service ( + +) inherits confdroid_ntp::params { + require confdroid_ntp::main::files +} diff --git a/manifests/params.pp b/manifests/params.pp index 6a61d65..d78565d 100644 --- a/manifests/params.pp +++ b/manifests/params.pp @@ -2,8 +2,16 @@ # Module name: confdroid_ntp # Author: 12ww1160 (12ww1160@confdroid.com) # @summary Class contains all parameters for the confdroid_ntp module. +# @param [Array] cy_reqpackages List of required packages to install +# for the confdroid_ntp module. +# @param [String] cy_pkg_ensure Ensure state of the required packages. ############################################################################## class confdroid_ntp::params ( + +# installation + Array $cy_reqpackages = ['chrony'], + String $cy_pkg_ensure = 'present', + ) { # defaults $fqdn = $facts['networking']['fqdn']