From 01366a62b941fee91ad6595c794472580e191fa2 Mon Sep 17 00:00:00 2001 From: treydock Date: Tue, 29 Aug 2023 13:35:26 -0400 Subject: [PATCH] (SIMP-10743) Support stdlib 9.x (#101) * (SIMP-10743) Support stdlib 9.x Replace legacy Integer with proper Integer to support stdlib 9 Fixes #96 * Bump version * Bump version to 6.8.0 * Add CHANGELOG entry * Add backwards compatibility for `verbose` parameter * Update REFERENCE.md --------- Co-authored-by: Mike Riddle Co-authored-by: Steven Pritchard --- CHANGELOG | 3 +++ REFERENCE.md | 13 ++++++++++--- manifests/init.pp | 5 ++++- metadata.json | 4 ++-- 4 files changed, 19 insertions(+), 6 deletions(-) diff --git a/CHANGELOG b/CHANGELOG index 37c0a80..e927c3e 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,6 @@ +* Fri Jul 28 2023 Trey Dockendorf - 6.8.0 +- Support stdlib 9.x + * Mon Jul 24 2023 Chris Tessmer - 6.7.0 - Add RockyLinux 8 support diff --git a/REFERENCE.md b/REFERENCE.md index 4f8bcbb..b2a17e2 100644 --- a/REFERENCE.md +++ b/REFERENCE.md @@ -105,11 +105,18 @@ Default value: `'yes'` ##### `verbose` -Data type: `Stdlib::Compat::Integer` +Data type: + +```puppet +Variant[ + Integer[0, 255], + Pattern[/\A(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\z/] + ] +``` The verbosity of the output messages. -Default value: `'5'` +Default value: `5` ##### `report_urls` @@ -298,7 +305,7 @@ Data type: `Integer` Maximum time to wait in seconds for AIDE database initialization -Default value: `$facts['processorcount'] ? { 1 => 1200, default => 300` +Default value: `$facts['processors']['count'] ? { 1 => 1200, default => 300` ##### `package_ensure` diff --git a/manifests/init.pp b/manifests/init.pp index 0d1e346..8f3fc22 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -121,7 +121,10 @@ String $database_name = 'aide.db.gz', String $database_out_name = 'aide.db.new.gz', Variant[Enum['yes','no'],Boolean] $gzip_dbout = 'yes', - Stdlib::Compat::Integer $verbose = '5', + Variant[ + Integer[0, 255], + Pattern[/\A(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\z/] + ] $verbose = 5, Array[String] $report_urls = [ 'file:@@{LOGDIR}/aide.report'], Stdlib::Absolutepath $ruledir = '/etc/aide.conf.d', Variant[Hash,Array[String]] $rules = {}, diff --git a/metadata.json b/metadata.json index 8e9fbf6..1ecdc0a 100644 --- a/metadata.json +++ b/metadata.json @@ -1,6 +1,6 @@ { "name": "simp-aide", - "version": "6.7.0", + "version": "6.8.0", "author": "SIMP Team", "summary": "manages AIDE", "license": "Apache-2.0", @@ -22,7 +22,7 @@ }, { "name": "puppetlabs/stdlib", - "version_requirement": ">= 8.0.0 < 9.0.0" + "version_requirement": ">= 8.0.0 < 10.0.0" }, { "name": "puppetlabs/concat",