diff --git a/.rubocop.yml b/.rubocop.yml index bab25db5..5307849e 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -40,6 +40,10 @@ Style/BlockDelimiters: Description: Prefer braces for chaining. Mostly an aesthetical choice. Better to be consistent then. EnforcedStyle: braces_for_chaining +Style/BracesAroundHashParameters: + Description: Braces are required by Ruby 2.7. Cop removed from RuboCop v0.80.0. + See https://github.com/rubocop-hq/rubocop/pull/7643 + Enabled: true Style/ClassAndModuleChildren: Description: Compact style reduces the required amount of indentation. EnforcedStyle: compact diff --git a/CHANGELOG.md b/CHANGELOG.md index 4e6835fc..aac27b9b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,10 +4,18 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org). -## Date TBD - Release - 2.3.x +## 2020-7-17 - Release - 2.3.1 ### Changes - Added the `puppet_metrics_dashboard::profile::dbcompiler::install` class to mitigate CVE-2020-7943. + - Added a description to the influxdb yumrepo + - Updated Puppet VS Code Extension ID + - Datasource is now configurable on te system metrics graphs + - Replaced deprecated httpjson telegraf input with http + +### Bugfixes + - Fixed measurement names for process dashboards + - CI fixes ## 2020-4-15 - Release - 2.3.0 diff --git a/REFERENCE.md b/REFERENCE.md index 19c8d82a..885ace8c 100644 --- a/REFERENCE.md +++ b/REFERENCE.md @@ -8,6 +8,7 @@ _Public Classes_ * [`puppet_metrics_dashboard`](#puppet_metrics_dashboard): Installs and configures a stack for collecting, storing, and displaying Puppet Infrastructure metrics +* [`puppet_metrics_dashboard::profile::dbcompiler::install`](#puppet_metrics_dashboardprofiledbcompilerinstall): Apply this class to compilers running PuppetDB to configure Telegraf and collect puppetserver and puppetdb metrics * [`puppet_metrics_dashboard::profile::master::install`](#puppet_metrics_dashboardprofilemasterinstall): Install requirements for the voxpupuli/puppet-telegraf module * [`puppet_metrics_dashboard::profile::master::postgres_access`](#puppet_metrics_dashboardprofilemasterpostgres_access): Apply this class to a PE PostgreSQL node to allow access by Telegraf. * [`puppet_metrics_dashboard::profile::postgres`](#puppet_metrics_dashboardprofilepostgres): This class is deprecated. Please use the Puppet_metrics_dashboard::Profile::Master::Postgres_access class. @@ -341,6 +342,76 @@ Data type: `Puppet_metrics_dashboard::Puppetdb_metric` An Array of Hashes containing name/url pairs for each PuppetDB metric. Refer to `functions/puppetdb_metrics.pp` for defaults. +Default value: puppet_metrics_dashboard::puppetdb_metrics() + +### puppet_metrics_dashboard::profile::dbcompiler::install + +Apply this class to compilers running PuppetDB to configure Telegraf and collect puppetserver and puppetdb metrics + +#### Parameters + +The following parameters are available in the `puppet_metrics_dashboard::profile::dbcompiler::install` class. + +##### `influxdb_urls` + +Data type: `Array[String]` + +An Array containing urls defining InfluxDB instances for Telegraf. + +##### `timeout` + +Data type: `String[2]` + +Default timeout of http calls. Defaults to 5 seconds + +Default value: lookup('puppet_metrics_dashboard::http_response_timeout') + +##### `compiler` + +Data type: `Variant[String,Tuple[String, Integer]]` + +The FQDN of the compiler / master. Defaults to the FQDN of the server where the profile is applied + +Default value: $facts['networking']['fqdn'] + +##### `puppetdb_host` + +Data type: `Variant[String,Tuple[String, Integer]]` + +Where to query the puppetdb host. Defaults to localhost. + +Default value: 'localhost' + +##### `cm_port` + +Data type: `Integer[1]` + +The port that the puppetserver service listens on on your compiler. Defaults to 8140 + +Default value: 8140 + +##### `db_port` + +Data type: `Integer[1]` + +The port that the puppetdb service listens on on your compiler. Defaults to 8081 + +Default value: 8081 + +##### `interval` + +Data type: `String[2]` + +The frequency that telegraf will poll puppetserver metrics. Defaults to '5s' + +Default value: '5s' + +##### `puppetdb_metrics` + +Data type: `Puppet_metrics_dashboard::Puppetdb_metric` + + + Default value: puppet_metrics_dashboard::puppetdb_metrics() ### puppet_metrics_dashboard::profile::master::install diff --git a/metadata.json b/metadata.json index aef47deb..5e08e882 100644 --- a/metadata.json +++ b/metadata.json @@ -1,6 +1,6 @@ { "name": "puppetlabs-puppet_metrics_dashboard", - "version": "2.3.0", + "version": "2.3.1", "author": "puppetlabs", "summary": "A module for managing the installation and configuration of metrics dashboards for Puppet Infrastructure.", "license": "Apache-2.0", @@ -62,7 +62,7 @@ "version_requirement": ">= 4.7.0 < 7.0.0" } ], - "pdk-version": "1.17.0", - "template-url": "pdk-default#1.17.0", - "template-ref": "tags/1.17.0-0-gd3a4319" + "pdk-version": "1.18.0", + "template-url": "pdk-default#1.18.0", + "template-ref": "tags/1.18.0-0-g095317c" } diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 2b61ac28..bdc72574 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -42,6 +42,7 @@ # set to strictest setting for testing # by default Puppet runs at warning level Puppet.settings[:strict] = :warning + Puppet.settings[:strict_variables] = true end c.filter_run_excluding(bolt: true) unless ENV['GEM_BOLT'] c.after(:suite) do