Merge branch 'jenkins' into 'master'

Jenkins

See merge request !28
This commit is contained in:
12ww1160
2017-07-30 13:31:24 +02:00
21 changed files with 278 additions and 36 deletions

View File

@@ -8,6 +8,16 @@ Changelog of Git Changelog.
<h2> No issue </h2>
<a href="https://gitlab.puppetsoft.com/12WW1160/git-changelog-lib/commit/d9e6db5e0d5b277">d9e6db5e0d5b277</a> Arne Teuke <i>2017-07-30 11:32:29</i>
<p>
<h3>updated README, added defintions</h3>
</p>
<a href="https://gitlab.puppetsoft.com/12WW1160/git-changelog-lib/commit/3f047c24ddbd6ed">3f047c24ddbd6ed</a> Jenkins Server <i>2017-07-30 11:32:22</i>
<p>
<h3>recommit for updates in build 40</h3>
</p>
<a href="https://gitlab.puppetsoft.com/12WW1160/git-changelog-lib/commit/93c4d60d239af95">93c4d60d239af95</a> Arne Teuke <i>2017-07-28 18:49:03</i>
<p>
<h3>updated parameter</h3>

View File

@@ -7,7 +7,6 @@ NRPE allows monitoring tools like NAGIOS or ICINGA to connect to clients for mon
`cd_nrpe` is a fully parameterized Puppet module to automate NRPE installation and configuration.
### WARNING
`**__!!! Attention: Never use this puppet module on systems which have been previously configured manually. It is impossible to predict how and what would have been configured, hence previuos configurations outside the scope of this module may be overwritten! Automated configurations require a test environment to verify that the module suits the purpose intended by the user, as well as tune the parameters, before deploying into live production!!! __**`
@@ -39,6 +38,7 @@ CONFIGURATION
* manage configuration files through parameters:
* nrpe.conf
* nrpe.cfg
* commands.cfg (optional)
* manage iptables (optionals )
SERVICE
@@ -74,11 +74,10 @@ See [more details about class deployment on Confdroid.com](https://confdroid.com
### Parameters
The following parameters are editable via params.pp or through ENC (**__recommended__**). Values changed will take immediate effect at next puppet run. Services will be restarted where neccessary.
The following parameters are editable via params.pp or through ENC (**__recommended__**). Values changed will take immediate effect at next puppet run. Services will be restarted where neccessary. If you want to override parameters, the [module must be specifically declared to hosts when using ENC](#through-foreman).
### Mandatory Parameters
There are currently no mandatory parameters, i.e. the module will function right out of box as is.
### Optional Parameters

View File

@@ -9,6 +9,7 @@
| | |-- full_list.js
| | `-- jquery.js
| |-- puppet_classes
| | |-- cd_nrpe_3A_3Acommands_3A_3Adefinitions.html
| | |-- cd_nrpe_3A_3Afirewall_3A_3Aiptables.html
| | |-- cd_nrpe_3A_3Amain_3A_3Aconfig.html
| | |-- cd_nrpe_3A_3Amain_3A_3Adirs.html
@@ -59,4 +60,4 @@
|-- README.md
`-- REPOSTRUCTURE.md
11 directories, 48 files
11 directories, 49 files

View File

@@ -74,7 +74,7 @@
</li>
<li>
<span class='object_link'><a href="puppet_classes/cd_nrpe_3A_3Acommands_3A_3Adefinitions.html" title="puppet_classes::cd_nrpe::commands::definitions (puppet_class)">cd_nrpe::commands::definitions</a></span>
<span class='object_link'><a href="puppet_classes/cd_nrpe_3A_3Acommands_3A_3Adefinition_rules.html" title="puppet_classes::cd_nrpe::commands::definition_rules (puppet_class)">cd_nrpe::commands::definition_rules</a></span>
</li>
@@ -171,7 +171,7 @@
</div>
<div id="footer">
Generated on Sun Jul 30 13:32:17 2017 by
Generated on Sun Jul 30 13:41:58 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>

View File

@@ -133,7 +133,8 @@ manage configuration files through parameters:
* nrpe.conf
* nrpe.cfg
*
manage iptables (optionals )</p>
commands.cfg (optional)
* manage iptables (optionals )</p>
<p>SERVICE
* manage NRPE service</p>
@@ -192,7 +193,9 @@ details about class deployment on Confdroid.com</a>.</p>
<p>The following parameters are editable via params.pp or through ENC
(<strong>recommended</strong>). Values changed will take immediate effect
at next puppet run. Services will be restarted where neccessary.</p>
at next puppet run. Services will be restarted where neccessary. If you
want to override parameters, the <a href="#through-foreman">module must be
specifically declared to hosts when using ENC</a>.</p>
<h3 id="label-Mandatory+Parameters">Mandatory Parameters</h3>
@@ -274,7 +277,7 @@ environments.</p>
</div></div>
<div id="footer">
Generated on Sun Jul 30 13:32:18 2017 by
Generated on Sun Jul 30 13:41:59 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>

View File

@@ -133,7 +133,8 @@ manage configuration files through parameters:
* nrpe.conf
* nrpe.cfg
*
manage iptables (optionals )</p>
commands.cfg (optional)
* manage iptables (optionals )</p>
<p>SERVICE
* manage NRPE service</p>
@@ -192,7 +193,9 @@ details about class deployment on Confdroid.com</a>.</p>
<p>The following parameters are editable via params.pp or through ENC
(<strong>recommended</strong>). Values changed will take immediate effect
at next puppet run. Services will be restarted where neccessary.</p>
at next puppet run. Services will be restarted where neccessary. If you
want to override parameters, the <a href="#through-foreman">module must be
specifically declared to hosts when using ENC</a>.</p>
<h3 id="label-Mandatory+Parameters">Mandatory Parameters</h3>
@@ -274,7 +277,7 @@ environments.</p>
</div></div>
<div id="footer">
Generated on Sun Jul 30 13:32:17 2017 by
Generated on Sun Jul 30 13:41:58 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>

View File

@@ -47,9 +47,9 @@
</li>
<li id="object_puppet_classes::cd_nrpe::commands::definitions" class="even">
<li id="object_puppet_classes::cd_nrpe::commands::definition_rules" class="even">
<div class="item">
<span class='object_link'><a href="puppet_classes/cd_nrpe_3A_3Acommands_3A_3Adefinitions.html" title="puppet_classes::cd_nrpe::commands::definitions (puppet_class)">cd_nrpe::commands::definitions</a></span>
<span class='object_link'><a href="puppet_classes/cd_nrpe_3A_3Acommands_3A_3Adefinition_rules.html" title="puppet_classes::cd_nrpe::commands::definition_rules (puppet_class)">cd_nrpe::commands::definition_rules</a></span>
</div>
</li>

View File

@@ -140,7 +140,7 @@ class cd_nrpe {
</div>
<div id="footer">
Generated on Sun Jul 30 13:32:18 2017 by
Generated on Sun Jul 30 13:41:59 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>

View File

@@ -0,0 +1,217 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>
Puppet Class: cd_nrpe::commands::definition_rules
&mdash; 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_nrpe::commands::definition_rules";
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> &raquo;
<span class='title'><span class='object_link'>Puppet Classes</span></span>
&raquo;
<span class="title">cd_nrpe::commands::definition_rules</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_nrpe::commands::definition_rules</h1>
<div class="box_info">
<dl>
<dt>Inherits:</dt>
<dd><span class='object_link'><a href="cd_nrpe_3A_3Aparams.html" title="puppet_classes::cd_nrpe::params (puppet_class)">cd_nrpe::params</a></span></dd>
</dl>
<dl>
<dt>Defined in:</dt>
<dd>
manifests/commands/definition_rules.pp
</dd>
</dl>
</div>
<h2>Summary</h2>
manage command definitions via define and Puppet rules.
<h2>Overview</h2>
<div class="docstring">
<div class="discussion">
<p>cd_nrpe::commands::definition_rules.pp
Module name: cd_nrpe
Author: Arne
Teuke (arne_teuke@ConfDroid.com)</p>
<h1 id="label-License%3A">License:</h1>
<p>This file is part of cd_nrpe.</p>
<p>cd_nrpe is used for providing automatic configuration of NRPE.
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</pre>
</td>
<td>
<pre class="code"><span class="info file"># File 'manifests/commands/definition_rules.pp', line 23</span>
class cd_nrpe::commands::definition_rules (
) inherits cd_nrpe::params {
if $ne_manage_cmds == true {
# manage the commands.cfg file
concat { $ne_cmd_file:
ensure =&gt; present,
path =&gt; $ne_cmd_file,
owner =&gt; &#39;root&#39;,
group =&gt; &#39;root&#39;,
mode =&gt; &#39;0640&#39;,
selrange =&gt; s0,
selrole =&gt; object_r,
seltype =&gt; nrpe_etc_t,
seluser =&gt; system_u,
notify =&gt; Service[$ne_service],
}
# manage the file header
concat::fragment { &#39;nrpe_cmd_header&#39;:
target =&gt; $ne_cmd_file,
content =&gt; template($ne_cmd_head_erb),
order =&gt; &#39;000&#39;,
}
# basic example rules
}
}</pre>
</td>
</tr>
</table>
</div>
</div>
<div id="footer">
Generated on Sun Jul 30 13:42:00 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>

View File

@@ -165,7 +165,7 @@ class cd_nrpe::firewall::iptables (
</div>
<div id="footer">
Generated on Sun Jul 30 13:32:19 2017 by
Generated on Sun Jul 30 13:42:00 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>

View File

@@ -154,7 +154,7 @@ class cd_nrpe::main::config (
</div>
<div id="footer">
Generated on Sun Jul 30 13:32:19 2017 by
Generated on Sun Jul 30 13:42:00 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>

View File

@@ -205,7 +205,7 @@ class cd_nrpe::main::dirs (
</div>
<div id="footer">
Generated on Sun Jul 30 13:32:19 2017 by
Generated on Sun Jul 30 13:42:00 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>

View File

@@ -217,7 +217,7 @@ class cd_nrpe::main::files (
</div>
<div id="footer">
Generated on Sun Jul 30 13:32:19 2017 by
Generated on Sun Jul 30 13:42:00 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>

View File

@@ -160,7 +160,7 @@ class cd_nrpe::main::install (
</div>
<div id="footer">
Generated on Sun Jul 30 13:32:19 2017 by
Generated on Sun Jul 30 13:42:00 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>

View File

@@ -183,7 +183,7 @@ class cd_nrpe::main::service (
</div>
<div id="footer">
Generated on Sun Jul 30 13:32:19 2017 by
Generated on Sun Jul 30 13:42:00 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>

View File

@@ -193,7 +193,7 @@ class cd_nrpe::main::user (
</div>
<div id="footer">
Generated on Sun Jul 30 13:32:19 2017 by
Generated on Sun Jul 30 13:42:00 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>

View File

@@ -81,7 +81,7 @@
<span class='object_link'><a href="cd_nrpe_3A_3Afirewall_3A_3Aiptables.html" title="puppet_classes::cd_nrpe::firewall::iptables (puppet_class)">cd_nrpe::firewall::iptables</a></span><br/>
<span class='object_link'><a href="cd_nrpe_3A_3Acommands_3A_3Adefinitions.html" title="puppet_classes::cd_nrpe::commands::definitions (puppet_class)">cd_nrpe::commands::definitions</a></span><br/>
<span class='object_link'><a href="cd_nrpe_3A_3Acommands_3A_3Adefinition_rules.html" title="puppet_classes::cd_nrpe::commands::definition_rules (puppet_class)">cd_nrpe::commands::definition_rules</a></span><br/>
</dd>
</dl>
@@ -1059,7 +1059,7 @@ $ne_cmd_rule_erb = &#39;cd_nrpe/cmd_rule.erb&#39;
</div>
<div id="footer">
Generated on Sun Jul 30 13:32:19 2017 by
Generated on Sun Jul 30 13:42:00 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>

View File

@@ -203,7 +203,10 @@ checks.</p>
44
45
46
47</pre>
47
48
49
50</pre>
</td>
<td>
<pre class="code"><span class="info file"># File 'manifests/commands/definitions.pp', line 31</span>
@@ -218,12 +221,15 @@ $ne_cmd_argstring = undef,
$ne_cmd_file = $::cd_nrpe::params::ne_cmd_file
$ne_cmd_rule_erb = $::cd_nrpe::params::ne_cmd_rule_erb
$ne_manage_cmds = $::cd_nrpe::params::ne_manage_cmds
if $ne_manage_cmds == true {
concat::fragment { $name:
target =&gt; $ne_cmd_file,
content =&gt; template($ne_cmd_rule_erb),
}
}
}</pre>
</td>
</tr>
@@ -232,7 +238,7 @@ $ne_cmd_rule_erb = $::cd_nrpe::params::ne_cmd_rule_erb
</div>
<div id="footer">
Generated on Sun Jul 30 13:32:20 2017 by
Generated on Sun Jul 30 13:42:00 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>

View File

@@ -90,7 +90,7 @@
</div>
<div id="footer">
Generated on Sun Jul 30 13:32:18 2017 by
Generated on Sun Jul 30 13:41:59 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>

View File

@@ -20,7 +20,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# @summary manage command definitions via define and Puppet rules.
###############################################################################
class cd_nrpe::commands::definitions (
class cd_nrpe::commands::definition_rules (
) inherits cd_nrpe::params {

View File

@@ -38,10 +38,13 @@ $ne_cmd_argstring = undef,
$ne_cmd_file = $::cd_nrpe::params::ne_cmd_file
$ne_cmd_rule_erb = $::cd_nrpe::params::ne_cmd_rule_erb
$ne_manage_cmds = $::cd_nrpe::params::ne_manage_cmds
if $ne_manage_cmds == true {
concat::fragment { $name:
target => $ne_cmd_file,
content => template($ne_cmd_rule_erb),
}
}
}