From 2a2883a1e30c65afaf80a42cb2d814e8379a31e5 Mon Sep 17 00:00:00 2001 From: Tim Meusel Date: Tue, 1 Oct 2024 14:25:43 +0200 Subject: [PATCH 1/2] Replace legacy `fqdn` fact with `networking.fqdn` --- lib/puppet/face/catalog/pull.rb | 2 +- lib/puppet/face/catalog/seed.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/puppet/face/catalog/pull.rb b/lib/puppet/face/catalog/pull.rb index 5b10b71..8bd9c6b 100644 --- a/lib/puppet/face/catalog/pull.rb +++ b/lib/puppet/face/catalog/pull.rb @@ -19,7 +19,7 @@ option '--new_server=' do summary 'This the valid certificate name or alt name for your old server' - default_to { Facter.value('fqdn') } + default_to { Facter.value('networking.fqdn') } end option '--threads=' do diff --git a/lib/puppet/face/catalog/seed.rb b/lib/puppet/face/catalog/seed.rb index db49c1f..16faf0e 100644 --- a/lib/puppet/face/catalog/seed.rb +++ b/lib/puppet/face/catalog/seed.rb @@ -12,7 +12,7 @@ option '--master_server SERVER' do summary 'The server from which to download the catalogs from' - default_to { Facter.value('fqdn') } + default_to { Facter.value('networkin.fqdn') } end option '--certless' do From 898c7f936adfcee6a9364885e50073e9a62da405 Mon Sep 17 00:00:00 2001 From: Tim Meusel Date: Tue, 1 Oct 2024 14:33:38 +0200 Subject: [PATCH 2/2] document all parameters with puppet-strings --- .puppet-lint.rc | 1 - .sync.yml | 1 + REFERENCE.md | 66 +++++++++++++++++++++++++++++++++++++++++++++ manifests/viewer.pp | 9 +++++++ 4 files changed, 76 insertions(+), 1 deletion(-) create mode 100644 REFERENCE.md diff --git a/.puppet-lint.rc b/.puppet-lint.rc index 420e819..37817b6 100644 --- a/.puppet-lint.rc +++ b/.puppet-lint.rc @@ -2,4 +2,3 @@ # https://voxpupuli.org/docs/updating-files-managed-with-modulesync/ --fail-on-warnings ---no-parameter_documentation-check diff --git a/.sync.yml b/.sync.yml index 08da294..079eb29 100644 --- a/.sync.yml +++ b/.sync.yml @@ -2,3 +2,4 @@ .puppet-lint.rc: enabled_lint_checks: - parameter_types + - parameter_documentation diff --git a/REFERENCE.md b/REFERENCE.md new file mode 100644 index 0000000..403550a --- /dev/null +++ b/REFERENCE.md @@ -0,0 +1,66 @@ +# Reference + + + +## Table of Contents + +### Classes + +* [`catalog_diff::viewer`](#catalog_diff--viewer): installs the catalog-diff viewer + +## Classes + +### `catalog_diff::viewer` + +installs the catalog-diff viewer + +#### Parameters + +The following parameters are available in the `catalog_diff::viewer` class: + +* [`remote`](#-catalog_diff--viewer--remote) +* [`password`](#-catalog_diff--viewer--password) +* [`revision`](#-catalog_diff--viewer--revision) +* [`port`](#-catalog_diff--viewer--port) +* [`listen_ip`](#-catalog_diff--viewer--listen_ip) + +##### `remote` + +Data type: `String` + +the url to the git repo of the catalog diff viewer + +Default value: `'https://github.com/voxpupuli/puppet-catalog-diff-viewer.git'` + +##### `password` + +Data type: `String` + +password for basic authentication + +Default value: `'puppet'` + +##### `revision` + +Data type: `String` + +the desired branch/rev that you want to checkout + +Default value: `'master'` + +##### `port` + +Data type: `Integer` + +where apache will listen on + +Default value: `1495` + +##### `listen_ip` + +Data type: `String` + +the desired ip adddress to listen on + +Default value: `$facts['networking']['ip']` + diff --git a/manifests/viewer.pp b/manifests/viewer.pp index 99c7406..2c20509 100644 --- a/manifests/viewer.pp +++ b/manifests/viewer.pp @@ -1,3 +1,12 @@ +# +# @summary installs the catalog-diff viewer +# +# @param remote the url to the git repo of the catalog diff viewer +# @param password password for basic authentication +# @param revision the desired branch/rev that you want to checkout +# @param port where apache will listen on +# @param listen_ip the desired ip adddress to listen on +# class catalog_diff::viewer ( String $remote = 'https://github.com/voxpupuli/puppet-catalog-diff-viewer.git', String $password = 'puppet',