15
CHANGELOG.md
15
CHANGELOG.md
@@ -8,6 +8,21 @@ Changelog of Git Changelog.
|
|||||||
<h2> No issue </h2>
|
<h2> No issue </h2>
|
||||||
|
|
||||||
|
|
||||||
|
<a href="https://gitlab.puppetsoft.com/12WW1160/git-changelog-lib/commit/92e809e1c65f745">92e809e1c65f745</a> Jenkins Server <i>2017-07-21 16:38:00</i>
|
||||||
|
<p>
|
||||||
|
<h3>recommit for updates in build 44</h3>
|
||||||
|
|
||||||
|
</p>
|
||||||
|
<a href="https://gitlab.puppetsoft.com/12WW1160/git-changelog-lib/commit/35150e65ab10a1c">35150e65ab10a1c</a> Arne Teuke <i>2017-07-21 16:37:42</i>
|
||||||
|
<p>
|
||||||
|
<h3>syntax</h3>
|
||||||
|
|
||||||
|
</p>
|
||||||
|
<a href="https://gitlab.puppetsoft.com/12WW1160/git-changelog-lib/commit/72d8f34299acd31">72d8f34299acd31</a> Arne Teuke <i>2017-07-21 16:34:48</i>
|
||||||
|
<p>
|
||||||
|
<h3>adding selinux control</h3>
|
||||||
|
|
||||||
|
</p>
|
||||||
<a href="https://gitlab.puppetsoft.com/12WW1160/git-changelog-lib/commit/5d8c5cff034540a">5d8c5cff034540a</a> Jenkins Server <i>2017-07-21 16:28:39</i>
|
<a href="https://gitlab.puppetsoft.com/12WW1160/git-changelog-lib/commit/5d8c5cff034540a">5d8c5cff034540a</a> Jenkins Server <i>2017-07-21 16:28:39</i>
|
||||||
<p>
|
<p>
|
||||||
<h3>recommit for updates in build 42</h3>
|
<h3>recommit for updates in build 42</h3>
|
||||||
|
|||||||
@@ -33,7 +33,7 @@
|
|||||||
| `-- top-level-namespace.html
|
| `-- top-level-namespace.html
|
||||||
|-- manifests
|
|-- manifests
|
||||||
| |-- certbot
|
| |-- certbot
|
||||||
| | `-- config.pp
|
| | `-- certs.pp
|
||||||
| |-- client
|
| |-- client
|
||||||
| | `-- target.pp
|
| | `-- target.pp
|
||||||
| |-- firewall
|
| |-- firewall
|
||||||
|
|||||||
@@ -74,7 +74,7 @@
|
|||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li>
|
<li>
|
||||||
<span class='object_link'><a href="puppet_classes/cd_nagios_3A_3Acertbot_3A_3Aconfig.html" title="puppet_classes::cd_nagios::certbot::config (puppet_class)">cd_nagios::certbot::config</a></span>
|
<span class='object_link'><a href="puppet_classes/cd_nagios_3A_3Acertbot_3A_3Acerts.html" title="puppet_classes::cd_nagios::certbot::certs (puppet_class)">cd_nagios::certbot::certs</a></span>
|
||||||
|
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
@@ -186,7 +186,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
Generated on Fri Jul 21 18:37:54 2017 by
|
Generated on Sat Jul 22 13:38:49 2017 by
|
||||||
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
0.9.9 (ruby-2.0.0).
|
0.9.9 (ruby-2.0.0).
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -304,7 +304,7 @@ environments.</p>
|
|||||||
</div></div>
|
</div></div>
|
||||||
|
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
Generated on Fri Jul 21 18:37:55 2017 by
|
Generated on Sat Jul 22 13:38:50 2017 by
|
||||||
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
0.9.9 (ruby-2.0.0).
|
0.9.9 (ruby-2.0.0).
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -304,7 +304,7 @@ environments.</p>
|
|||||||
</div></div>
|
</div></div>
|
||||||
|
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
Generated on Fri Jul 21 18:37:55 2017 by
|
Generated on Sat Jul 22 13:38:50 2017 by
|
||||||
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
0.9.9 (ruby-2.0.0).
|
0.9.9 (ruby-2.0.0).
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -47,9 +47,9 @@
|
|||||||
</li>
|
</li>
|
||||||
|
|
||||||
|
|
||||||
<li id="object_puppet_classes::cd_nagios::certbot::config" class="even">
|
<li id="object_puppet_classes::cd_nagios::certbot::certs" class="even">
|
||||||
<div class="item">
|
<div class="item">
|
||||||
<span class='object_link'><a href="puppet_classes/cd_nagios_3A_3Acertbot_3A_3Aconfig.html" title="puppet_classes::cd_nagios::certbot::config (puppet_class)">cd_nagios::certbot::config</a></span>
|
<span class='object_link'><a href="puppet_classes/cd_nagios_3A_3Acertbot_3A_3Acerts.html" title="puppet_classes::cd_nagios::certbot::certs (puppet_class)">cd_nagios::certbot::certs</a></span>
|
||||||
</div>
|
</div>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
|
|||||||
@@ -139,7 +139,7 @@ class cd_nagios {
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
Generated on Fri Jul 21 18:37:56 2017 by
|
Generated on Sat Jul 22 13:38:50 2017 by
|
||||||
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
0.9.9 (ruby-2.0.0).
|
0.9.9 (ruby-2.0.0).
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
300
doc/puppet_classes/cd_nagios_3A_3Acertbot_3A_3Acerts.html
Normal file
300
doc/puppet_classes/cd_nagios_3A_3Acertbot_3A_3Acerts.html
Normal file
@@ -0,0 +1,300 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<title>
|
||||||
|
Puppet Class: cd_nagios::certbot::certs
|
||||||
|
|
||||||
|
— Documentation by YARD 0.9.9
|
||||||
|
|
||||||
|
</title>
|
||||||
|
|
||||||
|
<link rel="stylesheet" href="../css/style.css" type="text/css" charset="utf-8" />
|
||||||
|
|
||||||
|
<link rel="stylesheet" href="../css/common.css" type="text/css" charset="utf-8" />
|
||||||
|
|
||||||
|
<script type="text/javascript" charset="utf-8">
|
||||||
|
pathId = "puppet_classes::cd_nagios::certbot::certs";
|
||||||
|
relpath = '../';
|
||||||
|
</script>
|
||||||
|
|
||||||
|
|
||||||
|
<script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
|
||||||
|
|
||||||
|
<script type="text/javascript" charset="utf-8" src="../js/app.js"></script>
|
||||||
|
|
||||||
|
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<div class="nav_wrap">
|
||||||
|
<iframe id="nav" src="../puppet_class_list.html?1"></iframe>
|
||||||
|
<div id="resizer"></div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="main" tabindex="-1">
|
||||||
|
<div id="header">
|
||||||
|
<div id="menu">
|
||||||
|
|
||||||
|
<a href="../_index.html">Index (c)</a> »
|
||||||
|
<span class='title'><span class='object_link'>Puppet Classes</span></span>
|
||||||
|
»
|
||||||
|
<span class="title">cd_nagios::certbot::certs</span>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="search">
|
||||||
|
|
||||||
|
<a class="full_list_link" id="puppet_class_list_link"
|
||||||
|
href="../puppet_class_list.html">
|
||||||
|
|
||||||
|
<svg width="24" height="24">
|
||||||
|
<rect x="0" y="4" width="24" height="4" rx="1" ry="1"></rect>
|
||||||
|
<rect x="0" y="12" width="24" height="4" rx="1" ry="1"></rect>
|
||||||
|
<rect x="0" y="20" width="24" height="4" rx="1" ry="1"></rect>
|
||||||
|
</svg>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="clear"></div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="content"><h1>Puppet Class: cd_nagios::certbot::certs</h1>
|
||||||
|
<div class="box_info">
|
||||||
|
|
||||||
|
<dl>
|
||||||
|
<dt>Inherits:</dt>
|
||||||
|
<dd><span class='object_link'><a href="cd_nagios_3A_3Aparams.html" title="puppet_classes::cd_nagios::params (puppet_class)">cd_nagios::params</a></span></dd>
|
||||||
|
</dl>
|
||||||
|
|
||||||
|
|
||||||
|
<dl>
|
||||||
|
<dt>Defined in:</dt>
|
||||||
|
<dd>
|
||||||
|
manifests/certbot/certs.pp
|
||||||
|
</dd>
|
||||||
|
</dl>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<h2>Summary</h2>
|
||||||
|
Class manages all configuration files required for cd_nagios.
|
||||||
|
|
||||||
|
<h2>Overview</h2>
|
||||||
|
<div class="docstring">
|
||||||
|
<div class="discussion">
|
||||||
|
|
||||||
|
<p>cd_nagios::certbot::certs.pp
|
||||||
|
Module name: cd_nagios
|
||||||
|
Author: Arne Teuke
|
||||||
|
(arne_teuke@ConfDroid.com)</p>
|
||||||
|
|
||||||
|
<h1 id="label-License%3A">License:</h1>
|
||||||
|
|
||||||
|
<p>This file is part of cd_nagios.</p>
|
||||||
|
|
||||||
|
<p>cd_nagios is used for providing automatic configuration of Nagios
|
||||||
|
|
||||||
|
Copyright (C) 2016 ConfDroid (copyright@ConfDroid.com)
|
||||||
|
This program is
|
||||||
|
free software: you can redistribute it and/or modify
|
||||||
|
it under the terms of
|
||||||
|
the GNU General Public License as published by
|
||||||
|
the Free Software
|
||||||
|
Foundation, either version 3 of the License, or
|
||||||
|
(at your option) any later
|
||||||
|
version.</p>
|
||||||
|
|
||||||
|
<p>This program is distributed in the hope that it will be useful,
|
||||||
|
but
|
||||||
|
WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY
|
||||||
|
or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License
|
||||||
|
for more details.</p>
|
||||||
|
|
||||||
|
<p>You should have received a copy of the GNU General Public License
|
||||||
|
along
|
||||||
|
with this program. If not, see <a
|
||||||
|
href="http://www.gnu.org/licenses">www.gnu.org/licenses</a>/.</p>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="tags">
|
||||||
|
|
||||||
|
|
||||||
|
</div><div class="method_details_list">
|
||||||
|
<table class="source_code">
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
<pre class="lines">
|
||||||
|
|
||||||
|
|
||||||
|
23
|
||||||
|
24
|
||||||
|
25
|
||||||
|
26
|
||||||
|
27
|
||||||
|
28
|
||||||
|
29
|
||||||
|
30
|
||||||
|
31
|
||||||
|
32
|
||||||
|
33
|
||||||
|
34
|
||||||
|
35
|
||||||
|
36
|
||||||
|
37
|
||||||
|
38
|
||||||
|
39
|
||||||
|
40
|
||||||
|
41
|
||||||
|
42
|
||||||
|
43
|
||||||
|
44
|
||||||
|
45
|
||||||
|
46
|
||||||
|
47
|
||||||
|
48
|
||||||
|
49
|
||||||
|
50
|
||||||
|
51
|
||||||
|
52
|
||||||
|
53
|
||||||
|
54
|
||||||
|
55
|
||||||
|
56
|
||||||
|
57
|
||||||
|
58
|
||||||
|
59
|
||||||
|
60
|
||||||
|
61
|
||||||
|
62
|
||||||
|
63
|
||||||
|
64
|
||||||
|
65
|
||||||
|
66
|
||||||
|
67
|
||||||
|
68
|
||||||
|
69
|
||||||
|
70
|
||||||
|
71
|
||||||
|
72
|
||||||
|
73
|
||||||
|
74
|
||||||
|
75
|
||||||
|
76
|
||||||
|
77
|
||||||
|
78
|
||||||
|
79
|
||||||
|
80
|
||||||
|
81
|
||||||
|
82
|
||||||
|
83
|
||||||
|
84
|
||||||
|
85
|
||||||
|
86
|
||||||
|
87
|
||||||
|
88
|
||||||
|
89
|
||||||
|
90
|
||||||
|
91
|
||||||
|
92
|
||||||
|
93
|
||||||
|
94
|
||||||
|
95
|
||||||
|
96
|
||||||
|
97</pre>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<pre class="code"><span class="info file"># File 'manifests/certbot/certs.pp', line 23</span>
|
||||||
|
|
||||||
|
class cd_nagios::certbot::certs (
|
||||||
|
|
||||||
|
) inherits cd_nagios::params {
|
||||||
|
|
||||||
|
if $::fqdn == $ng_nagios_server {
|
||||||
|
if $ng_use_https == true {
|
||||||
|
if $ng_enable_certbot == true {
|
||||||
|
|
||||||
|
require cd_certbot
|
||||||
|
require cd_apache
|
||||||
|
|
||||||
|
# ensure there is no forward vhost file
|
||||||
|
|
||||||
|
exec { 'remove_forward_vhost':
|
||||||
|
command => "rm -Rf ${ng_forward_conf}",
|
||||||
|
creates => '/etc/httpd/conf.d/.cert_created',
|
||||||
|
}
|
||||||
|
|
||||||
|
exec { 'remove_nagios_conf':
|
||||||
|
command => "rm -Rf ${ng_nagios_conf}",
|
||||||
|
creates => '/etc/httpd/conf.d/.cert_created',
|
||||||
|
require => Exec['remove_forward_vhost'],
|
||||||
|
}
|
||||||
|
|
||||||
|
exec { 'remove_index_html':
|
||||||
|
command => "rm -Rf ${ng_index_html_file}",
|
||||||
|
creates => '/etc/httpd/conf.d/.cert_created',
|
||||||
|
require => Exec['remove_nagios_conf'],
|
||||||
|
notify => Service[$ae_service],
|
||||||
|
}
|
||||||
|
|
||||||
|
exec { 'disable_selinux_temporarily':
|
||||||
|
command => 'setenforce 0',
|
||||||
|
path => ['/usr/sbin'],
|
||||||
|
creates => '/etc/httpd/conf.d/.cert_created',
|
||||||
|
require => Exec['remove_index_html'],
|
||||||
|
}
|
||||||
|
|
||||||
|
# create cert
|
||||||
|
|
||||||
|
exec { 'create_cert':
|
||||||
|
command => template($ng_get_cert_erb),
|
||||||
|
cwd => '/tmp',
|
||||||
|
path => ['/bin','/usr/bin'],
|
||||||
|
provider => 'shell',
|
||||||
|
unless => template('cd_nagios/certbot/unless_get_cert.erb'),
|
||||||
|
notify => Service['httpd'],
|
||||||
|
creates => '/etc/httpd/conf.d/.cert_created',
|
||||||
|
}
|
||||||
|
|
||||||
|
exec { 'enable_selinux':
|
||||||
|
command => 'setenforce 1',
|
||||||
|
path => ['/usr/sbin'],
|
||||||
|
creates => '/etc/httpd/conf.d/.cert_created',
|
||||||
|
require => Exec['create_cert'],
|
||||||
|
}
|
||||||
|
|
||||||
|
# renew certs
|
||||||
|
|
||||||
|
exec { 'renew_cert':
|
||||||
|
command => 'certbot renew',
|
||||||
|
cwd => '/tmp',
|
||||||
|
path => ['/bin','/usr/bin','/opt/'],
|
||||||
|
provider => 'shell',
|
||||||
|
notify => Service['httpd'],
|
||||||
|
unless => template($ng_unless_renew_erb),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
else {
|
||||||
|
# do nothing as we are not using https and certbot is not required then
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}</pre>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="footer">
|
||||||
|
Generated on Sat Jul 22 13:38:52 2017 by
|
||||||
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
|
0.9.9 (ruby-2.0.0).
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
@@ -368,7 +368,7 @@ class cd_nagios::client::target (
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
Generated on Fri Jul 21 18:37:57 2017 by
|
Generated on Sat Jul 22 13:38:52 2017 by
|
||||||
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
0.9.9 (ruby-2.0.0).
|
0.9.9 (ruby-2.0.0).
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -207,7 +207,7 @@ class cd_nagios::firewall::iptables (
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
Generated on Fri Jul 21 18:37:58 2017 by
|
Generated on Sat Jul 22 13:38:52 2017 by
|
||||||
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
0.9.9 (ruby-2.0.0).
|
0.9.9 (ruby-2.0.0).
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -152,7 +152,11 @@ href="http://www.gnu.org/licenses">www.gnu.org/licenses</a>/.</p>
|
|||||||
43
|
43
|
||||||
44
|
44
|
||||||
45
|
45
|
||||||
46</pre>
|
46
|
||||||
|
47
|
||||||
|
48
|
||||||
|
49
|
||||||
|
50</pre>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<pre class="code"><span class="info file"># File 'manifests/main/config.pp', line 24</span>
|
<pre class="code"><span class="info file"># File 'manifests/main/config.pp', line 24</span>
|
||||||
@@ -164,14 +168,18 @@ class cd_nagios::main::config (
|
|||||||
# manage server configuration
|
# manage server configuration
|
||||||
|
|
||||||
if $::fqdn == $ng_nagios_server {
|
if $::fqdn == $ng_nagios_server {
|
||||||
include cd_nagios::server::service
|
# include cd_nagios::server::service
|
||||||
|
|
||||||
if $ng_include_fw == true {
|
# if $ng_include_fw == true {
|
||||||
include cd_nagios::firewall::iptables
|
# include cd_nagios::firewall::iptables
|
||||||
}
|
# }
|
||||||
|
|
||||||
if $ng_use_selinux_tools == true {
|
# if $ng_use_selinux_tools == true {
|
||||||
include cd_nagios::selinux::config
|
# include cd_nagios::selinux::config
|
||||||
|
# }
|
||||||
|
|
||||||
|
if $ng_enable_certbot == true {
|
||||||
|
require cd_nagios::certbot::certs
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -187,7 +195,7 @@ class cd_nagios::main::config (
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
Generated on Fri Jul 21 18:37:57 2017 by
|
Generated on Sat Jul 22 13:38:52 2017 by
|
||||||
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
0.9.9 (ruby-2.0.0).
|
0.9.9 (ruby-2.0.0).
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -468,7 +468,7 @@ class cd_nagios::main::dirs (
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
Generated on Fri Jul 21 18:37:57 2017 by
|
Generated on Sat Jul 22 13:38:51 2017 by
|
||||||
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
0.9.9 (ruby-2.0.0).
|
0.9.9 (ruby-2.0.0).
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -235,7 +235,7 @@ class cd_nagios::main::install (
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
Generated on Fri Jul 21 18:37:57 2017 by
|
Generated on Sat Jul 22 13:38:52 2017 by
|
||||||
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
0.9.9 (ruby-2.0.0).
|
0.9.9 (ruby-2.0.0).
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -200,7 +200,7 @@ class cd_nagios::main::user (
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
Generated on Fri Jul 21 18:37:57 2017 by
|
Generated on Sat Jul 22 13:38:52 2017 by
|
||||||
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
0.9.9 (ruby-2.0.0).
|
0.9.9 (ruby-2.0.0).
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -77,9 +77,9 @@
|
|||||||
|
|
||||||
<span class='object_link'><a href="cd_nagios_3A_3Aserver_3A_3Afiles.html" title="puppet_classes::cd_nagios::server::files (puppet_class)">cd_nagios::server::files</a></span><br/>
|
<span class='object_link'><a href="cd_nagios_3A_3Aserver_3A_3Afiles.html" title="puppet_classes::cd_nagios::server::files (puppet_class)">cd_nagios::server::files</a></span><br/>
|
||||||
|
|
||||||
<span class='object_link'><a href="cd_nagios_3A_3Aclient_3A_3Atarget.html" title="puppet_classes::cd_nagios::client::target (puppet_class)">cd_nagios::client::target</a></span><br/>
|
<span class='object_link'><a href="cd_nagios_3A_3Acertbot_3A_3Acerts.html" title="puppet_classes::cd_nagios::certbot::certs (puppet_class)">cd_nagios::certbot::certs</a></span><br/>
|
||||||
|
|
||||||
<span class='object_link'><a href="cd_nagios_3A_3Acertbot_3A_3Aconfig.html" title="puppet_classes::cd_nagios::certbot::config (puppet_class)">cd_nagios::certbot::config</a></span><br/>
|
<span class='object_link'><a href="cd_nagios_3A_3Aclient_3A_3Atarget.html" title="puppet_classes::cd_nagios::client::target (puppet_class)">cd_nagios::client::target</a></span><br/>
|
||||||
|
|
||||||
<span class='object_link'><a href="cd_nagios_3A_3Aselinux_3A_3Aconfig.html" title="puppet_classes::cd_nagios::selinux::config (puppet_class)">cd_nagios::selinux::config</a></span><br/>
|
<span class='object_link'><a href="cd_nagios_3A_3Aselinux_3A_3Aconfig.html" title="puppet_classes::cd_nagios::selinux::config (puppet_class)">cd_nagios::selinux::config</a></span><br/>
|
||||||
|
|
||||||
@@ -1934,6 +1934,30 @@ well as for certbot.</p>
|
|||||||
<p>Whether to create an index file to allow
|
<p>Whether to create an index file to allow
|
||||||
httpd checks with nagios on the
|
httpd checks with nagios on the
|
||||||
nagios server.</p>
|
nagios server.</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
|
||||||
|
<span class='name'>ng_webserver_name</span>
|
||||||
|
|
||||||
|
|
||||||
|
<span class='type'>(<tt>string</tt>)</span>
|
||||||
|
|
||||||
|
|
||||||
|
<em class="default">(defaults to: <tt>"nagios.${::domain}"</tt>)</em>
|
||||||
|
|
||||||
|
|
||||||
|
—
|
||||||
|
<div class='inline'>
|
||||||
|
<p>the name of the web server nagios should
|
||||||
|
listen to, i.e.
|
||||||
|
'nagios.example.net'. Unlike <code>ng_nagios_server</code>,
|
||||||
|
this
|
||||||
|
should not be the FQDN of the nagios host, but a web server domain
|
||||||
|
name.
|
||||||
|
required for certbot and used in the web templates.</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</li>
|
</li>
|
||||||
@@ -1955,10 +1979,6 @@ nagios server.</p>
|
|||||||
<pre class="lines">
|
<pre class="lines">
|
||||||
|
|
||||||
|
|
||||||
212
|
|
||||||
213
|
|
||||||
214
|
|
||||||
215
|
|
||||||
216
|
216
|
||||||
217
|
217
|
||||||
218
|
218
|
||||||
@@ -2127,10 +2147,15 @@ nagios server.</p>
|
|||||||
381
|
381
|
||||||
382
|
382
|
||||||
383
|
383
|
||||||
384</pre>
|
384
|
||||||
|
385
|
||||||
|
386
|
||||||
|
387
|
||||||
|
388
|
||||||
|
389</pre>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<pre class="code"><span class="info file"># File 'manifests/params.pp', line 212</span>
|
<pre class="code"><span class="info file"># File 'manifests/params.pp', line 216</span>
|
||||||
|
|
||||||
class cd_nagios::params (
|
class cd_nagios::params (
|
||||||
|
|
||||||
@@ -2247,6 +2272,7 @@ $ng_enable_index = true,
|
|||||||
# certbot
|
# certbot
|
||||||
$ng_enable_certbot = true,
|
$ng_enable_certbot = true,
|
||||||
$ng_certbot_cert_path = '/var/www/html',
|
$ng_certbot_cert_path = '/var/www/html',
|
||||||
|
$ng_webserver_name = "nagios.${::domain}",
|
||||||
|
|
||||||
) {
|
) {
|
||||||
|
|
||||||
@@ -2312,7 +2338,7 @@ $ng_index_html_erb = 'cd_nagios/httpd/index_html.erb'
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
Generated on Fri Jul 21 18:37:57 2017 by
|
Generated on Sat Jul 22 13:38:51 2017 by
|
||||||
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
0.9.9 (ruby-2.0.0).
|
0.9.9 (ruby-2.0.0).
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -249,7 +249,7 @@ class cd_nagios::selinux::config (
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
Generated on Fri Jul 21 18:37:58 2017 by
|
Generated on Sat Jul 22 13:38:52 2017 by
|
||||||
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
0.9.9 (ruby-2.0.0).
|
0.9.9 (ruby-2.0.0).
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -195,7 +195,7 @@ class cd_nagios::server::access_rules (
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
Generated on Fri Jul 21 18:37:58 2017 by
|
Generated on Sat Jul 22 13:38:52 2017 by
|
||||||
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
0.9.9 (ruby-2.0.0).
|
0.9.9 (ruby-2.0.0).
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -344,7 +344,7 @@ class cd_nagios::server::files (
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
Generated on Fri Jul 21 18:37:57 2017 by
|
Generated on Sat Jul 22 13:38:52 2017 by
|
||||||
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
0.9.9 (ruby-2.0.0).
|
0.9.9 (ruby-2.0.0).
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -174,7 +174,7 @@ class cd_nagios::server::service (
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
Generated on Fri Jul 21 18:37:58 2017 by
|
Generated on Sat Jul 22 13:38:52 2017 by
|
||||||
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
0.9.9 (ruby-2.0.0).
|
0.9.9 (ruby-2.0.0).
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -220,7 +220,7 @@ $ng_service = $::cd_nagios::params::ng_service
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
Generated on Fri Jul 21 18:37:58 2017 by
|
Generated on Sat Jul 22 13:38:53 2017 by
|
||||||
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
0.9.9 (ruby-2.0.0).
|
0.9.9 (ruby-2.0.0).
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -90,7 +90,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
Generated on Fri Jul 21 18:37:55 2017 by
|
Generated on Sat Jul 22 13:38:50 2017 by
|
||||||
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
<a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
|
||||||
0.9.9 (ruby-2.0.0).
|
0.9.9 (ruby-2.0.0).
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
## cd_nagios::certbot::config.pp
|
## cd_nagios::certbot::certs.pp
|
||||||
# Module name: cd_nagios
|
# Module name: cd_nagios
|
||||||
# Author: Arne Teuke (arne_teuke@ConfDroid.com)
|
# Author: Arne Teuke (arne_teuke@ConfDroid.com)
|
||||||
# # License:
|
# # License:
|
||||||
@@ -20,7 +20,7 @@
|
|||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
# @summary Class manages all configuration files required for cd_nagios.
|
# @summary Class manages all configuration files required for cd_nagios.
|
||||||
##############################################################################
|
##############################################################################
|
||||||
class cd_nagios::certbot::config (
|
class cd_nagios::certbot::certs (
|
||||||
|
|
||||||
) inherits cd_nagios::params {
|
) inherits cd_nagios::params {
|
||||||
|
|
||||||
@@ -29,6 +29,7 @@ class cd_nagios::certbot::config (
|
|||||||
if $ng_enable_certbot == true {
|
if $ng_enable_certbot == true {
|
||||||
|
|
||||||
require cd_certbot
|
require cd_certbot
|
||||||
|
require cd_apache
|
||||||
|
|
||||||
# ensure there is no forward vhost file
|
# ensure there is no forward vhost file
|
||||||
|
|
||||||
@@ -28,14 +28,18 @@ class cd_nagios::main::config (
|
|||||||
# manage server configuration
|
# manage server configuration
|
||||||
|
|
||||||
if $::fqdn == $ng_nagios_server {
|
if $::fqdn == $ng_nagios_server {
|
||||||
include cd_nagios::server::service
|
# include cd_nagios::server::service
|
||||||
|
|
||||||
if $ng_include_fw == true {
|
# if $ng_include_fw == true {
|
||||||
include cd_nagios::firewall::iptables
|
# include cd_nagios::firewall::iptables
|
||||||
}
|
# }
|
||||||
|
|
||||||
if $ng_use_selinux_tools == true {
|
# if $ng_use_selinux_tools == true {
|
||||||
include cd_nagios::selinux::config
|
# include cd_nagios::selinux::config
|
||||||
|
# }
|
||||||
|
|
||||||
|
if $ng_enable_certbot == true {
|
||||||
|
require cd_nagios::certbot::certs
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -208,6 +208,10 @@
|
|||||||
# used for nagios itself as well as for certbot.
|
# used for nagios itself as well as for certbot.
|
||||||
# @param [boolean] ng_enable_index Whether to create an index file to allow
|
# @param [boolean] ng_enable_index Whether to create an index file to allow
|
||||||
# httpd checks with nagios on the nagios server.
|
# httpd checks with nagios on the nagios server.
|
||||||
|
# @param [string] ng_webserver_name the name of the web server nagios should
|
||||||
|
# listen to, i.e. 'nagios.example.net'. Unlike `ng_nagios_server`, this
|
||||||
|
# should not be the FQDN of the nagios host, but a web server domain name.
|
||||||
|
# required for certbot and used in the web templates.
|
||||||
###############################################################################
|
###############################################################################
|
||||||
class cd_nagios::params (
|
class cd_nagios::params (
|
||||||
|
|
||||||
@@ -324,6 +328,7 @@ $ng_enable_index = true,
|
|||||||
# certbot
|
# certbot
|
||||||
$ng_enable_certbot = true,
|
$ng_enable_certbot = true,
|
||||||
$ng_certbot_cert_path = '/var/www/html',
|
$ng_certbot_cert_path = '/var/www/html',
|
||||||
|
$ng_webserver_name = "nagios.${::domain}",
|
||||||
|
|
||||||
) {
|
) {
|
||||||
|
|
||||||
|
|||||||
@@ -1,2 +1,2 @@
|
|||||||
certbot certonly -t -n --agree-tos --webroot -w <%= @ng_certbot_cert_path %>/ -d <%= @ng_nagios_server %> --email <%= @ng_mail_user %>
|
certbot certonly -t -n --agree-tos --webroot -w <%= @ng_certbot_cert_path %>/ -d www.<%= @ng_webserver_name %> -d <%= @ng_webserver_name %> --email <%= @ng_mail_user %>
|
||||||
touch /etc/httpd/conf.d/.cert_created
|
touch /etc/httpd/conf.d/.cert_created
|
||||||
|
|||||||
@@ -1,17 +1,17 @@
|
|||||||
<VirtualHost *:<%= @ng_http_port %>>
|
<VirtualHost *:<%= @ng_http_port %>>
|
||||||
ServerAdmin root@localhost
|
ServerAdmin root@localhost
|
||||||
DocumentRoot /var/www/html
|
DocumentRoot /var/www/html
|
||||||
ServerName www.<%= @ng_nagios_server %>
|
ServerName www.<%= @ng_webserver_name %>
|
||||||
ServerAlias <%= @ng_nagios_server %>
|
ServerAlias <%= @ng_webserver_name %>
|
||||||
<% if @ng_use_https == true -%>
|
<% if @ng_use_https == true -%>
|
||||||
Redirect permanent / https://<%= @ng_nagios_server %>/nagios
|
Redirect permanent / https://<%= @ng_webserver_name %>/nagios
|
||||||
<% end -%>
|
<% end -%>
|
||||||
<% if @ng_use_https != true -%>
|
<% if @ng_use_https != true -%>
|
||||||
Redirect permanent / http://<%= @ng_nagios_server %>/nagios
|
Redirect permanent / http://<%= @ng_webserver_name %>/nagios
|
||||||
<% end -%>
|
<% end -%>
|
||||||
<Directory />
|
<Directory />
|
||||||
AllowOverride All
|
AllowOverride All
|
||||||
</Directory>
|
</Directory>
|
||||||
ErrorLog /var/log/httpd/<%= @ng_nagios_server %>-error_log
|
ErrorLog /var/log/httpd/<%= @ng_webserver_name %>-error_log
|
||||||
CustomLog /var/log/httpd/<%= @ng_nagios_server %>-access_log common
|
CustomLog /var/log/httpd/<%= @ng_webserver_name %>-access_log common
|
||||||
</VirtualHost>
|
</VirtualHost>
|
||||||
|
|||||||
Reference in New Issue
Block a user