Skip to content

Commit 9c468b3

Browse files
authored
Merge pull request #1412 from ekohl/puppet-strings
Convert documentation to puppet-strings
2 parents e88ffae + 3cf092a commit 9c468b3

16 files changed

+954
-765
lines changed

manifests/config.pp

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,5 @@
1-
# Class: nginx::config
2-
#
3-
# This module manages NGINX bootstrap and configuration
4-
#
5-
# Parameters:
6-
#
7-
# There are no default parameters for this class.
8-
#
9-
# Actions:
10-
#
11-
# Requires:
12-
#
13-
# Sample Usage:
14-
#
15-
# This class file is not called directly
1+
# @summary Manage NGINX bootstrap and configuration
2+
# @api private
163
class nginx::config {
174
assert_private()
185

manifests/init.pp

Lines changed: 6 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,12 @@
1-
# @summary
2-
# This module manages NGINX.
1+
# @summary Manage NGINX
32
#
4-
# Parameters:
3+
# Packaged NGINX
4+
# - RHEL: EPEL or custom package
5+
# - Debian/Ubuntu: Default Install or custom package
6+
# - SuSE: Default Install or custom package
57
#
6-
# Actions:
7-
#
8-
# Requires:
9-
# puppetlabs-stdlib - https://github.com/puppetlabs/puppetlabs-stdlib
10-
#
11-
# Packaged NGINX
12-
# - RHEL: EPEL or custom package
13-
# - Debian/Ubuntu: Default Install or custom package
14-
# - SuSE: Default Install or custom package
15-
#
16-
# stdlib
17-
# - puppetlabs-stdlib module >= 0.1.6
18-
#
19-
# Sample Usage:
20-
#
21-
# The module works with sensible defaults:
22-
#
23-
# node default {
8+
# @example Use the sensible defaults
249
# include nginx
25-
# }
2610
#
2711
# @param include_modules_enabled
2812
# When set, nginx will include module configurations files installed in the

manifests/package.pp

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,5 @@
1-
# Class: nginx::package
2-
#
3-
# This module manages NGINX package installation
4-
#
5-
# Parameters:
6-
#
7-
# There are no default parameters for this class.
8-
#
9-
# Actions:
10-
#
11-
# Requires:
12-
#
13-
# Sample Usage:
14-
#
15-
# This class file is not called directly
1+
# @summary Manage NGINX package installation
2+
# @api private
163
class nginx::package {
174
$package_name = $nginx::package_name
185
$package_source = $nginx::package_source

manifests/package/debian.pp

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,5 @@
1-
# Class: nginx::package::debian
2-
#
3-
# This module manages NGINX package installation on debian based systems
4-
#
5-
# Parameters:
6-
#
7-
# There are no default parameters for this class.
8-
#
9-
# Actions:
10-
#
11-
# Requires:
12-
#
13-
# Sample Usage:
14-
#
15-
# This class file is not called directly
1+
# @summary Manage NGINX package installation on debian based systems
2+
# @api private
163
class nginx::package::debian {
174
$package_name = $nginx::package_name
185
$package_source = $nginx::package_source

manifests/package/redhat.pp

Lines changed: 2 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,5 @@
1-
# Class: nginx::package::redhat
2-
#
3-
# This module manages NGINX package installation on RedHat based systems
4-
#
5-
# Parameters:
6-
#
7-
# There are no default parameters for this class.
8-
#
9-
# Actions:
10-
#
11-
# Requires:
12-
#
13-
# Sample Usage:
14-
#
15-
# This class file is not called directly
1+
# @summary Manage NGINX package installation on RedHat based systems
2+
# @api private
163
class nginx::package::redhat {
174
$package_name = $nginx::package_name
185
$package_source = $nginx::package_source

manifests/params.pp

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,5 @@
1-
# Class: nginx::params
2-
# ====================
3-
#
4-
# nginx default settings and according to operating system
5-
#
1+
# @summary default settings and according to operating system
2+
# @api private
63
class nginx::params {
74
### Operating System Configuration
85
## This is my hacky... no hiera system. Oh well. :)

manifests/resource/geo.pp

Lines changed: 48 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1,56 +1,59 @@
1-
# define: nginx::resource::geo
1+
# @summary Create a new geo mapping entry for NGINX
22
#
3-
# This definition creates a new geo mapping entry for NGINX
3+
# @param networks
4+
# Hash of geo lookup keys and resultant values
45
#
5-
# Parameters:
6-
# [*networks*] - Hash of geo lookup keys and resultant values
7-
# [*default*] - Sets the resulting value if the source value fails to
8-
# match any of the variants.
9-
# [*ensure*] - Enables or disables the specified location
10-
# [*ranges*] - Indicates that lookup keys (network addresses) are
11-
# specified as ranges.
12-
# [*address*] - Nginx defaults to using $remote_addr for testing.
13-
# This allows you to override that with another variable
14-
# name (automatically prefixed with $)
15-
# [*delete*] - deletes the specified network (see: geo module docs)
16-
# [*proxy_recursive*] - Changes the behavior of address acquisition when
17-
# specifying trusted proxies via 'proxies' directive
18-
# [*proxies*] - Hash of network->value mappings.
6+
# @param default
7+
# Sets the resulting value if the source value fails to match any of the
8+
# variants.
199
#
20-
# Actions:
10+
# @param ensure
11+
# Enables or disables the specified location
2112
#
22-
# Requires:
13+
# @param ranges
14+
# Indicates that lookup keys (network addresses) are specified as ranges.
2315
#
24-
# Sample Usage:
16+
# @param address
17+
# Nginx defaults to using $remote_addr for testing. This allows you to
18+
# override that with another variable name (automatically prefixed with $)
2519
#
26-
# nginx::resource::geo { 'client_network':
27-
# ensure => present,
28-
# ranges => false,
29-
# default => extra,
30-
# proxy_recursive => false,
31-
# proxies => [ '192.168.99.99' ],
32-
# networks => {
33-
# '10.0.0.0/8' => 'intra',
34-
# '172.16.0.0/12' => 'intra',
35-
# '192.168.0.0/16' => 'intra',
36-
# }
37-
# }
20+
# @param delete
21+
# deletes the specified network (see: geo module docs)
3822
#
39-
# Sample Hiera usage:
23+
# @param proxy_recursive
24+
# Changes the behavior of address acquisition when specifying trusted
25+
# proxies via 'proxies' directive
4026
#
41-
# nginx::geo_mappings:
42-
# client_network:
43-
# ensure: present
44-
# ranges: false
45-
# default: 'extra'
46-
# proxy_recursive: false
47-
# proxies:
48-
# - 192.168.99.99
49-
# networks:
50-
# '10.0.0.0/8': 'intra'
51-
# '172.16.0.0/12': 'intra'
52-
# '192.168.0.0/16': 'intra'
53-
27+
# @param proxies
28+
# Hash of network->value mappings.
29+
#
30+
# @example Puppet usage
31+
# nginx::resource::geo { 'client_network':
32+
# ensure => present,
33+
# ranges => false,
34+
# default => extra,
35+
# proxy_recursive => false,
36+
# proxies => [ '192.168.99.99' ],
37+
# networks => {
38+
# '10.0.0.0/8' => 'intra',
39+
# '172.16.0.0/12' => 'intra',
40+
# '192.168.0.0/16' => 'intra',
41+
# }
42+
# }
43+
#
44+
# @example Hiera usage
45+
# nginx::geo_mappings:
46+
# client_network:
47+
# ensure: present
48+
# ranges: false
49+
# default: 'extra'
50+
# proxy_recursive: false
51+
# proxies:
52+
# - 192.168.99.99
53+
# networks:
54+
# '10.0.0.0/8': 'intra'
55+
# '172.16.0.0/12': 'intra'
56+
# '192.168.0.0/16': 'intra'
5457
define nginx::resource::geo (
5558
Hash $networks,
5659
Optional[String] $default = undef,

0 commit comments

Comments
 (0)