Skip to content

Commit ddfc369

Browse files
authored
Merge pull request #6 from kenyon/alphabetize-docs
Alphabetize and fix generation of docs
2 parents c178168 + 2b06250 commit ddfc369

File tree

3 files changed

+34
-18
lines changed

3 files changed

+34
-18
lines changed

REFERENCE.md

Lines changed: 27 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919
### Defined types
2020

21-
* [`bind::key`](#bindkey)
21+
* [`bind::key`](#bindkey): Create TSIG key for zone updates in the configuration file for BIND
2222
* [`bind::zone`](#bindzone): A DNS zone
2323

2424
### Resource types
@@ -77,6 +77,7 @@ The following parameters are available in the `bind` class:
7777
* [`doc_packages_ensure`](#doc_packages_ensure)
7878
* [`utils_packages_ensure`](#utils_packages_ensure)
7979
* [`logging`](#logging)
80+
* [`keys`](#keys)
8081
* [`options`](#options)
8182
* [`package_manage`](#package_manage)
8283
* [`service_manage`](#service_manage)
@@ -102,7 +103,6 @@ The following parameters are available in the `bind` class:
102103
* [`zone_default_rname`](#zone_default_rname)
103104
* [`zone_default_serial`](#zone_default_serial)
104105
* [`zone_default_ttl`](#zone_default_ttl)
105-
* [`keys`](#keys)
106106

107107
##### <a name="authoritative"></a>`authoritative`
108108

@@ -209,6 +209,14 @@ statement](https://bind9.readthedocs.io/en/latest/reference.html#logging-stateme
209209

210210
Default value: ``undef``
211211

212+
##### <a name="keys"></a>`keys`
213+
214+
Data type: `Hash`
215+
216+
Hash for creating Bind::Key resources.
217+
218+
Default value: `{}`
219+
212220
##### <a name="options"></a>`options`
213221

214222
Data type: `Optional[Bind::Options]`
@@ -434,19 +442,25 @@ in the `$zones` parameter. Also, individual resource records can override this v
434442

435443
Default value: `'2d'`
436444

437-
##### <a name="keys"></a>`keys`
445+
## Defined types
438446

439-
Data type: `Hash`
447+
### <a name="bindkey"></a>`bind::key`
440448

441-
Hash for creating Bind::Key resources.
449+
Create TSIG key for zone updates in the configuration file for BIND
442450

443-
Default value: `{}`
451+
* **See also**
452+
* https://bind9.readthedocs.io/en/latest/advanced.html#tsig
444453

445-
## Defined types
454+
#### Examples
446455

447-
### <a name="bindkey"></a>`bind::key`
456+
##### Add a TSIG key to the nameserver
448457

449-
The bind::key class.
458+
```puppet
459+
bind::key { 'tsig-client':
460+
algorithm => 'hmac-sha512',
461+
secret => 'secret-key-data',
462+
}
463+
```
450464

451465
#### Parameters
452466

@@ -459,13 +473,15 @@ The following parameters are available in the `bind::key` defined type:
459473

460474
Data type: `Enum['hmac-sha256', 'hmac-sha384', 'hmac-sha512']`
461475

462-
476+
Defines the algorithm which was used to generate the key data.
477+
For security reasons just allow algorithms hmac-sha256 and above:
478+
https://www.rfc-editor.org/rfc/rfc8945.html#name-algorithms-and-identifiers
463479

464480
##### <a name="secret"></a>`secret`
465481

466482
Data type: `String[44]`
467483

468-
484+
Provide the secret data of the TSIG key, generated using tsig-keygen.
469485

470486
### <a name="bindzone"></a>`bind::zone`
471487

manifests/init.pp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,9 @@
4848
# Configuration of the [logging
4949
# statement](https://bind9.readthedocs.io/en/latest/reference.html#logging-statement-grammar).
5050
#
51+
# @param keys
52+
# Hash for creating Bind::Key resources.
53+
#
5154
# @param options
5255
# Configuration of the [options
5356
# statement](https://bind9.readthedocs.io/en/latest/reference.html#options-statement-grammar).
@@ -148,9 +151,6 @@
148151
# in the `$zones` parameter. Also, individual resource records can override this value with the
149152
# `ttl` key in their hashes. Reference: [RFC 2308](https://tools.ietf.org/html/rfc2308#section-4)
150153
#
151-
# @param keys
152-
# Hash for creating Bind::Key resources.
153-
#
154154
class bind (
155155
Boolean $authoritative = false,
156156
Stdlib::Absolutepath $config_dir = '/etc/bind',
@@ -164,6 +164,7 @@
164164
Optional[String[1]] $dev_packages_ensure = undef,
165165
Optional[String[1]] $doc_packages_ensure = undef,
166166
String[1] $utils_packages_ensure = 'installed',
167+
Hash $keys = {},
167168
Optional[Bind::Logging] $logging = undef,
168169
Optional[Bind::Options] $options = undef,
169170
Boolean $package_backport = false,
@@ -191,7 +192,6 @@
191192
String[1] $zone_default_rname = 'hostmaster',
192193
Integer[0] $zone_default_serial = 1,
193194
String[1] $zone_default_ttl = '2d',
194-
Hash $keys = {},
195195
) {
196196
contain bind::install
197197
contain bind::config

manifests/key.pp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
# SPDX-License-Identifier: AGPL-3.0-or-later
22

3-
# @summary Create TSIG key for zone updates in the configuration file for BIND domain name server.
4-
# Technical details: https://bind9.readthedocs.io/en/latest/advanced.html#tsig
3+
# @summary Create TSIG key for zone updates in the configuration file for BIND
4+
#
5+
# @see https://bind9.readthedocs.io/en/latest/advanced.html#tsig
56
#
67
# @example Add a TSIG key to the nameserver
78
# bind::key { 'tsig-client':
@@ -16,7 +17,6 @@
1617
#
1718
# @param secret
1819
# Provide the secret data of the TSIG key, generated using tsig-keygen.
19-
2020
define bind::key (
2121
Enum['hmac-sha256', 'hmac-sha384', 'hmac-sha512'] $algorithm,
2222
String[44] $secret,

0 commit comments

Comments
 (0)