Skip to content

Commit 91a9a6d

Browse files
committed
add docs, doc stubs and descriptions to fix validate warnings
1 parent ab148b5 commit 91a9a6d

File tree

15 files changed

+211
-118
lines changed

15 files changed

+211
-118
lines changed

REFERENCE.md

Lines changed: 55 additions & 81 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
#### Public Classes
1010

11-
* [`mongodb::client`](#mongodb--client): Class for installing a MongoDB client shell (CLI). == Parameters $ensure:: Desired ensure state of the package. $package_name:: Name of th
11+
* [`mongodb::client`](#mongodb--client): Class for installing a MongoDB client shell (CLI).
1212
* [`mongodb::globals`](#mongodb--globals): Class for setting cross-class global overrides. See README.md for more details.
1313
* [`mongodb::mongos`](#mongodb--mongos): This installs a Mongo Shard daemon. See README.md for more details.
1414
* [`mongodb::mongos::config`](#mongodb--mongos--config): PRIVATE CLASS: do not call directly
@@ -34,7 +34,7 @@
3434

3535
### Defined types
3636

37-
* [`mongodb::db`](#mongodb--db): == Class: mongodb::db Class for creating mongodb databases and users. == Parameters user - Database username. auth_mechanism - Authentic
37+
* [`mongodb::db`](#mongodb--db): Class for creating mongodb databases and users.
3838

3939
### Resource types
4040

@@ -54,13 +54,6 @@
5454

5555
Class for installing a MongoDB client shell (CLI).
5656

57-
== Parameters
58-
59-
$ensure:: Desired ensure state of the package.
60-
61-
$package_name:: Name of the package to install the client from. Default is
62-
repository dependent.
63-
6457
#### Parameters
6558

6659
The following parameters are available in the `mongodb::client` class:
@@ -72,22 +65,21 @@ The following parameters are available in the `mongodb::client` class:
7265

7366
Data type: `String[1]`
7467

75-
68+
Desired ensure state of the package.
7669

7770
Default value: `$mongodb::client::params::package_ensure`
7871

7972
##### <a name="-mongodb--client--package_name"></a>`package_name`
8073

8174
Data type: `String[1]`
8275

83-
76+
Name of the package to install the client from. Default is repository dependent.
8477

8578
Default value: `$mongodb::client::params::package_name`
8679

8780
### <a name="mongodb--globals"></a>`mongodb::globals`
8881

89-
Class for setting cross-class global overrides. See README.md for more
90-
details.
82+
Class for setting cross-class global overrides. See README.md for more details.
9183

9284
#### Parameters
9385

@@ -777,11 +769,6 @@ The following parameters are available in the `mongodb::opsmanager` class:
777769

778770
* [`user`](#-mongodb--opsmanager--user)
779771
* [`group`](#-mongodb--opsmanager--group)
780-
* [`opsmanager_url`](#-mongodb--opsmanager--opsmanager_url)
781-
* [`opsmanager_mongo_uri`](#-mongodb--opsmanager--opsmanager_mongo_uri)
782-
* [`ca_file`](#-mongodb--opsmanager--ca_file)
783-
* [`pem_key_file`](#-mongodb--opsmanager--pem_key_file)
784-
* [`pem_key_password`](#-mongodb--opsmanager--pem_key_password)
785772
* [`ensure`](#-mongodb--opsmanager--ensure)
786773
* [`package_name`](#-mongodb--opsmanager--package_name)
787774
* [`package_ensure`](#-mongodb--opsmanager--package_ensure)
@@ -790,6 +777,7 @@ The following parameters are available in the `mongodb::opsmanager` class:
790777
* [`service_name`](#-mongodb--opsmanager--service_name)
791778
* [`download_url`](#-mongodb--opsmanager--download_url)
792779
* [`mongo_uri`](#-mongodb--opsmanager--mongo_uri)
780+
* [`opsmanager_url`](#-mongodb--opsmanager--opsmanager_url)
793781
* [`client_certificate_mode`](#-mongodb--opsmanager--client_certificate_mode)
794782
* [`from_email_addr`](#-mongodb--opsmanager--from_email_addr)
795783
* [`reply_to_email_addr`](#-mongodb--opsmanager--reply_to_email_addr)
@@ -800,6 +788,9 @@ The following parameters are available in the `mongodb::opsmanager` class:
800788
* [`smtp_server_port`](#-mongodb--opsmanager--smtp_server_port)
801789
* [`ssl`](#-mongodb--opsmanager--ssl)
802790
* [`ignore_ui_setup`](#-mongodb--opsmanager--ignore_ui_setup)
791+
* [`ca_file`](#-mongodb--opsmanager--ca_file)
792+
* [`pem_key_file`](#-mongodb--opsmanager--pem_key_file)
793+
* [`pem_key_password`](#-mongodb--opsmanager--pem_key_password)
803794
* [`user_svc_class`](#-mongodb--opsmanager--user_svc_class)
804795
* [`snapshot_interval`](#-mongodb--opsmanager--snapshot_interval)
805796
* [`snapshot_interval_retention`](#-mongodb--opsmanager--snapshot_interval_retention)
@@ -824,42 +815,6 @@ The group that owns the config file
824815

825816
Default value: `'mongodb-mms'`
826817

827-
##### <a name="-mongodb--opsmanager--opsmanager_url"></a>`opsmanager_url`
828-
829-
Data type: `Stdlib::Httpurl`
830-
831-
The fully qualified url where opsmanager runs. Must include the port.
832-
833-
Default value: `"http://${facts['networking']['fqdn']}:8080"`
834-
835-
##### <a name="-mongodb--opsmanager--opsmanager_mongo_uri"></a>`opsmanager_mongo_uri`
836-
837-
Full URI where the Ops Manager application mongodb server(s) can be found.
838-
839-
##### <a name="-mongodb--opsmanager--ca_file"></a>`ca_file`
840-
841-
Data type: `Optional[String[1]]`
842-
843-
Ca file for secure connection to backup agents.
844-
845-
Default value: `undef`
846-
847-
##### <a name="-mongodb--opsmanager--pem_key_file"></a>`pem_key_file`
848-
849-
Data type: `Optional[String[1]]`
850-
851-
Pem key file containing the cert and private key used for secure connections to backup agents.
852-
853-
Default value: `undef`
854-
855-
##### <a name="-mongodb--opsmanager--pem_key_password"></a>`pem_key_password`
856-
857-
Data type: `Optional[String[1]]`
858-
859-
The password to the pem key file.
860-
861-
Default value: `undef`
862-
863818
##### <a name="-mongodb--opsmanager--ensure"></a>`ensure`
864819

865820
Data type: `Enum['running', 'stopped']`
@@ -924,6 +879,14 @@ Data type: `String[1]`
924879

925880
Default value: `'mongodb://127.0.0.1:27017'`
926881

882+
##### <a name="-mongodb--opsmanager--opsmanager_url"></a>`opsmanager_url`
883+
884+
Data type: `Stdlib::Httpurl`
885+
886+
The fully qualified url where opsmanager runs. Must include the port.
887+
888+
Default value: `"http://${facts['networking']['fqdn']}:8080"`
889+
927890
##### <a name="-mongodb--opsmanager--client_certificate_mode"></a>`client_certificate_mode`
928891

929892
Data type: `String[1]`
@@ -1004,6 +967,30 @@ Data type: `Boolean`
1004967

1005968
Default value: `true`
1006969

970+
##### <a name="-mongodb--opsmanager--ca_file"></a>`ca_file`
971+
972+
Data type: `Optional[String[1]]`
973+
974+
Ca file for secure connection to backup agents.
975+
976+
Default value: `undef`
977+
978+
##### <a name="-mongodb--opsmanager--pem_key_file"></a>`pem_key_file`
979+
980+
Data type: `Optional[String[1]]`
981+
982+
Pem key file containing the cert and private key used for secure connections to backup agents.
983+
984+
Default value: `undef`
985+
986+
##### <a name="-mongodb--opsmanager--pem_key_password"></a>`pem_key_password`
987+
988+
Data type: `Optional[String[1]]`
989+
990+
The password to the pem key file.
991+
992+
Default value: `undef`
993+
1007994
##### <a name="-mongodb--opsmanager--user_svc_class"></a>`user_svc_class`
1008995

1009996
Data type: `Optional[String[1]]`
@@ -1111,23 +1098,23 @@ Default value: `'present'`
11111098

11121099
Data type: `Optional[String]`
11131100

1114-
1101+
Optional repo version string.
11151102

11161103
Default value: `undef`
11171104

11181105
##### <a name="-mongodb--repo--use_enterprise_repo"></a>`use_enterprise_repo`
11191106

11201107
Data type: `Boolean`
11211108

1122-
1109+
Boolean value to use enterprise repository. Defaults to false.
11231110

11241111
Default value: `false`
11251112

11261113
##### <a name="-mongodb--repo--repo_location"></a>`repo_location`
11271114

11281115
Data type: `Optional[String]`
11291116

1130-
1117+
Optional location of the repository
11311118

11321119
Default value: `undef`
11331120

@@ -2006,21 +1993,8 @@ Default value: `undef`
20061993

20071994
### <a name="mongodb--db"></a>`mongodb::db`
20081995

2009-
== Class: mongodb::db
2010-
20111996
Class for creating mongodb databases and users.
20121997

2013-
== Parameters
2014-
2015-
user - Database username.
2016-
auth_mechanism - Authentication mechanism. scram_sha_256 password verification is not supported. Defaults to 'scram_sha_1'.
2017-
db_name - Database name. Defaults to $name.
2018-
password_hash - Hashed password. Hex encoded md5 hash of "$username:mongo:$password".
2019-
password - Plain text user password. This is UNSAFE, use 'password_hash' instead.
2020-
roles (default: ['dbAdmin']) - array with user roles.
2021-
tries (default: 10) - The maximum amount of two second tries to wait MongoDB startup.
2022-
update_password (default: false) - Force an update of the password when scram_sha_256 is used.
2023-
20241998
#### Parameters
20251999

20262000
The following parameters are available in the `mongodb::db` defined type:
@@ -2038,61 +2012,61 @@ The following parameters are available in the `mongodb::db` defined type:
20382012

20392013
Data type: `String`
20402014

2041-
2015+
Database username.
20422016

20432017
##### <a name="-mongodb--db--auth_mechanism"></a>`auth_mechanism`
20442018

20452019
Data type: `Enum['scram_sha_1', 'scram_sha_256']`
20462020

2047-
2021+
Authentication mechanism. scram_sha_256 password verification is not supported. Defaults to 'scram_sha_1'.
20482022

20492023
Default value: `'scram_sha_1'`
20502024

20512025
##### <a name="-mongodb--db--db_name"></a>`db_name`
20522026

20532027
Data type: `String`
20542028

2055-
2029+
Database name. Defaults to $name.
20562030

20572031
Default value: `$name`
20582032

20592033
##### <a name="-mongodb--db--password_hash"></a>`password_hash`
20602034

20612035
Data type: `Optional[Variant[String[1], Sensitive[String[1]]]]`
20622036

2063-
2037+
Hashed password. Hex encoded md5 hash of "$username:mongo:$password".
20642038

20652039
Default value: `undef`
20662040

20672041
##### <a name="-mongodb--db--password"></a>`password`
20682042

20692043
Data type: `Optional[Variant[String[1], Sensitive[String[1]]]]`
20702044

2071-
2045+
Plain text user password. This is UNSAFE, use 'password_hash' instead.
20722046

20732047
Default value: `undef`
20742048

20752049
##### <a name="-mongodb--db--roles"></a>`roles`
20762050

20772051
Data type: `Array[String]`
20782052

2079-
2053+
Array with user roles. Deaults to ['dbAdmin']
20802054

20812055
Default value: `['dbAdmin']`
20822056

20832057
##### <a name="-mongodb--db--tries"></a>`tries`
20842058

20852059
Data type: `Integer[0]`
20862060

2087-
2061+
The maximum amount of two second tries to wait MongoDB startup. Defaults to 10.
20882062

20892063
Default value: `10`
20902064

20912065
##### <a name="-mongodb--db--update_password"></a>`update_password`
20922066

20932067
Data type: `Boolean`
20942068

2095-
2069+
Force an update of the password when scram_sha_256 is used. Defaults to false.
20962070

20972071
Default value: `false`
20982072

@@ -2114,7 +2088,7 @@ The following properties are available in the `mongodb_conn_validator` type.
21142088

21152089
Valid values: `present`, `absent`
21162090

2117-
The basic property that the resource should be in.
2091+
Ensurable property
21182092

21192093
Default value: `present`
21202094

@@ -2216,7 +2190,7 @@ The following properties are available in the `mongodb_replset` type.
22162190

22172191
Valid values: `present`
22182192

2219-
The basic property that the resource should be in.
2193+
Ensurable property
22202194

22212195
Default value: `present`
22222196

@@ -2270,7 +2244,7 @@ The following properties are available in the `mongodb_shard` type.
22702244

22712245
Valid values: `present`
22722246

2273-
The basic property that the resource should be in.
2247+
Ensurable property
22742248

22752249
Default value: `present`
22762250

lib/puppet/type/mongodb_conn_validator.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
purposes such as monitoring."
99

1010
ensurable do
11+
desc 'Ensurable property'
1112
defaultvalues
1213
defaultto :present
1314
end

lib/puppet/type/mongodb_replset.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
@doc = 'Manage a MongoDB replicaSet'
99

1010
ensurable do
11+
desc 'Ensurable property'
1112
defaultto :present
1213

1314
newvalue(:present) do

lib/puppet/type/mongodb_shard.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
@doc = 'Manage a MongoDB Shard'
99

1010
ensurable do
11+
desc 'Ensurable property'
1112
defaultto :present
1213

1314
newvalue(:present) do

manifests/client.pp

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
1-
# Class for installing a MongoDB client shell (CLI).
1+
# @summary Class for installing a MongoDB client shell (CLI).
22
#
3-
# == Parameters
4-
#
5-
# $ensure:: Desired ensure state of the package.
6-
#
7-
# $package_name:: Name of the package to install the client from. Default is
8-
# repository dependent.
3+
# @param ensure
4+
# Desired ensure state of the package.
5+
# @param package_name
6+
# Name of the package to install the client from. Default is repository dependent.
97
#
108
class mongodb::client (
119
String[1] $ensure = $mongodb::client::params::package_ensure,

manifests/db.pp

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,21 @@
1-
# == Class: mongodb::db
1+
# @summary Class for creating mongodb databases and users.
22
#
3-
# Class for creating mongodb databases and users.
4-
#
5-
# == Parameters
6-
#
7-
# user - Database username.
8-
# auth_mechanism - Authentication mechanism. scram_sha_256 password verification is not supported. Defaults to 'scram_sha_1'.
9-
# db_name - Database name. Defaults to $name.
10-
# password_hash - Hashed password. Hex encoded md5 hash of "$username:mongo:$password".
11-
# password - Plain text user password. This is UNSAFE, use 'password_hash' instead.
12-
# roles (default: ['dbAdmin']) - array with user roles.
13-
# tries (default: 10) - The maximum amount of two second tries to wait MongoDB startup.
14-
# update_password (default: false) - Force an update of the password when scram_sha_256 is used.
3+
# @param user
4+
# Database username.
5+
# @param auth_mechanism
6+
# Authentication mechanism. scram_sha_256 password verification is not supported. Defaults to 'scram_sha_1'.
7+
# @param db_name
8+
# Database name. Defaults to $name.
9+
# @param password_hash
10+
# Hashed password. Hex encoded md5 hash of "$username:mongo:$password".
11+
# @param password
12+
# Plain text user password. This is UNSAFE, use 'password_hash' instead.
13+
# @param roles
14+
# Array with user roles. Deaults to ['dbAdmin']
15+
# @param tries
16+
# The maximum amount of two second tries to wait MongoDB startup. Defaults to 10.
17+
# @param update_password
18+
# Force an update of the password when scram_sha_256 is used. Defaults to false.
1519
#
1620
define mongodb::db (
1721
String $user,

0 commit comments

Comments
 (0)