Merge branch 'jenkins' into 'master'

Jenkins

See merge request !10
This commit is contained in:
12ww1160
2017-07-21 14:45:06 +02:00
22 changed files with 77 additions and 61 deletions

View File

@@ -8,6 +8,26 @@ Changelog of Git Changelog.
<h2> No issue </h2>
<a href="https://gitlab.puppetsoft.com/12WW1160/git-changelog-lib/commit/109eea2716be3ae">109eea2716be3ae</a> Jenkins Server <i>2017-07-21 11:35:04</i>
<p>
<h3>recommit for updates in build 18</h3>
</p>
<a href="https://gitlab.puppetsoft.com/12WW1160/git-changelog-lib/commit/5de81e818498830">5de81e818498830</a> Arne Teuke <i>2017-07-21 11:34:48</i>
<p>
<h3>testing options both for hosts and ips</h3>
</p>
<a href="https://gitlab.puppetsoft.com/12WW1160/git-changelog-lib/commit/41434c9607ab037">41434c9607ab037</a> Arne Teuke <i>2017-07-21 11:28:50</i>
<p>
<h3>adding options both for hosts and ips</h3>
</p>
<a href="https://gitlab.puppetsoft.com/12WW1160/git-changelog-lib/commit/544f48d800ad39a">544f48d800ad39a</a> Arne Teuke <i>2017-07-21 11:21:12</i>
<p>
<h3>adding options both for hosts and ips</h3>
</p>
<a href="https://gitlab.puppetsoft.com/12WW1160/git-changelog-lib/commit/969e377d5db6423">969e377d5db6423</a> Jenkins Server <i>2017-07-21 11:06:59</i>
<p>
<h3>recommit for updates in build 15</h3>

2
Jenkinsfile vendored
View File

@@ -202,6 +202,8 @@ Changelog of Git Changelog.
}
}
stage('recommit changes to repo') {
steps {
sshagent(['0c22dc63-2ae0-4ad5-98e0-65aa0f0f411g']) {

View File

@@ -9,6 +9,7 @@
| | |-- full_list.js
| | `-- jquery.js
| |-- puppet_classes
| | |-- cd_nagios_3A_3Aclient_3A_3Atarget.html
| | |-- cd_nagios_3A_3Afirewall_3A_3Aiptables.html
| | |-- cd_nagios_3A_3Amain_3A_3Aconfig.html
| | |-- cd_nagios_3A_3Amain_3A_3Adirs.html
@@ -67,4 +68,4 @@
|-- README.md
`-- REPOSTRUCTURE.md
16 directories, 51 files
16 directories, 52 files

View File

@@ -181,7 +181,7 @@
</div>
<div id="footer">
Generated on Fri Jul 21 13:34:58 2017 by
Generated on Fri Jul 21 14:51:27 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

@@ -297,7 +297,7 @@ environments.</p>
</div></div>
<div id="footer">
Generated on Fri Jul 21 13:34:59 2017 by
Generated on Fri Jul 21 14:51:29 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

@@ -297,7 +297,7 @@ environments.</p>
</div></div>
<div id="footer">
Generated on Fri Jul 21 13:34:59 2017 by
Generated on Fri Jul 21 14:51:28 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

@@ -139,7 +139,7 @@ class cd_nagios {
</div>
<div id="footer">
Generated on Fri Jul 21 13:34:59 2017 by
Generated on Fri Jul 21 14:51:29 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

@@ -368,7 +368,7 @@ class cd_nagios::client::target (
</div>
<div id="footer">
Generated on Fri Jul 21 13:35:01 2017 by
Generated on Fri Jul 21 14:51:31 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

@@ -207,7 +207,7 @@ class cd_nagios::firewall::iptables (
</div>
<div id="footer">
Generated on Fri Jul 21 13:35:01 2017 by
Generated on Fri Jul 21 14:51:31 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

@@ -187,7 +187,7 @@ class cd_nagios::main::config (
</div>
<div id="footer">
Generated on Fri Jul 21 13:35:01 2017 by
Generated on Fri Jul 21 14:51:30 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

@@ -468,7 +468,7 @@ class cd_nagios::main::dirs (
</div>
<div id="footer">
Generated on Fri Jul 21 13:35:01 2017 by
Generated on Fri Jul 21 14:51:30 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

@@ -235,7 +235,7 @@ class cd_nagios::main::install (
</div>
<div id="footer">
Generated on Fri Jul 21 13:35:01 2017 by
Generated on Fri Jul 21 14:51:30 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

@@ -200,7 +200,7 @@ class cd_nagios::main::user (
</div>
<div id="footer">
Generated on Fri Jul 21 13:35:01 2017 by
Generated on Fri Jul 21 14:51:30 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

@@ -1814,18 +1814,19 @@ enabled.</p>
<span class='name'>ng_required_hosts</span>
<span class='type'>(<tt>array</tt>)</span>
<span class='type'>(<tt>string</tt>)</span>
<em class="default">(defaults to: <tt>[&#39;&#39;]</tt>)</em>
<em class="default">(defaults to: <tt>&#39;&#39;</tt>)</em>
&mdash;
<div class='inline'>
<p>Array of <strong>FQDNs</strong> for hosts which
should be allowed/required.
every entry in the array creates a new line in
the configuration file.</p>
<p>String of <strong>FQDNs</strong> for hosts which
should be
allowed/required. Requires format
&#39;host1.example.com
host2.example.com&#39;</p>
</div>
</li>
@@ -1835,23 +1836,20 @@ the configuration file.</p>
<span class='name'>ng_required_ips</span>
<span class='type'>(<tt>array</tt>)</span>
<span class='type'>(<tt>string</tt>)</span>
<em class="default">(defaults to: <tt>[&#39;127.0.0.0/8&#39;]</tt>)</em>
<em class="default">(defaults to: <tt>&#39;127.0.0.0/8&#39;</tt>)</em>
&mdash;
<div class='inline'>
<p>Array of &lt;b&gt;_&lt;em&gt;Ip addresses __** for hosts which
<p>string of &lt;b&gt;_&lt;em&gt;Ip addresses __** for hosts which
should be
allowed/reqired. every entry in the array creates a new line in
the
configuration fileIp addresses _&lt;/em&gt;&lt;/b&gt; for hosts
which
should be allowed/reqired. every entry in the array creates a new
line in
the configuration file</p>
allowed/reqired. Requires format &#39;ipaddress ip address range&#39;Ip
addresses _&lt;/em&gt;&lt;/b&gt; for hosts which
should be allowed/reqired.
Requires format &#39;ipaddress ip address range&#39;</p>
</div>
</li>
@@ -1873,6 +1871,7 @@ the configuration file</p>
<pre class="lines">
203
204
205
206
@@ -2029,11 +2028,10 @@ the configuration file</p>
357
358
359
360
361</pre>
360</pre>
</td>
<td>
<pre class="code"><span class="info file"># File 'manifests/params.pp', line 204</span>
<pre class="code"><span class="info file"># File 'manifests/params.pp', line 203</span>
class cd_nagios::params (
@@ -2142,8 +2140,8 @@ $ng_ack_no_send = &#39;0&#39;,
$ng_use_selinux_tools = true,
# httpd
$ng_required_hosts = [&#39;&#39;],
$ng_required_ips = [&#39;127.0.0.0/8&#39;],
$ng_required_hosts = &#39;&#39;,
$ng_required_ips = &#39;127.0.0.0/8&#39;,
) {
@@ -2200,7 +2198,7 @@ $ng_nagios_conf_erb = &#39;cd_nagios/httpd/nagios_conf.erb&#39;
</div>
<div id="footer">
Generated on Fri Jul 21 13:35:01 2017 by
Generated on Fri Jul 21 14:51:30 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

@@ -249,7 +249,7 @@ class cd_nagios::selinux::config (
</div>
<div id="footer">
Generated on Fri Jul 21 13:35:01 2017 by
Generated on Fri Jul 21 14:51:31 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

@@ -195,7 +195,7 @@ class cd_nagios::server::access_rules (
</div>
<div id="footer">
Generated on Fri Jul 21 13:35:01 2017 by
Generated on Fri Jul 21 14:51:31 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

@@ -228,7 +228,7 @@ class cd_nagios::server::files (
</div>
<div id="footer">
Generated on Fri Jul 21 13:35:01 2017 by
Generated on Fri Jul 21 14:51:31 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

@@ -174,7 +174,7 @@ class cd_nagios::server::service (
</div>
<div id="footer">
Generated on Fri Jul 21 13:35:01 2017 by
Generated on Fri Jul 21 14:51:31 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

@@ -220,7 +220,7 @@ $ng_service = $::cd_nagios::params::ng_service
</div>
<div id="footer">
Generated on Fri Jul 21 13:35:02 2017 by
Generated on Fri Jul 21 14:51:31 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 Fri Jul 21 13:34:59 2017 by
Generated on Fri Jul 21 14:51:29 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

@@ -194,12 +194,11 @@
# "Send Notification" to be unchecked.
# @param [boolean] ng_use_selinux_tools Whether to enable selinux tools and
# policies. only effective if selinux is enabled.
# @param [array] ng_required_hosts Array of **__FQDNs__** for hosts which
# should be allowed/required. every entry in the array creates a new line in
# the configuration file.
# @param [array] ng_required_ips Array of **__Ip addresses __** for hosts which
# should be allowed/reqired. every entry in the array creates a new line in
# the configuration file
# @param [string] ng_required_hosts String of **__FQDNs__** for hosts which
# should be allowed/required. Requires format
# 'host1.example.com host2.example.com'
# @param [string] ng_required_ips string of **__Ip addresses __** for hosts which
# should be allowed/reqired. Requires format 'ipaddress ip address range'
###############################################################################
class cd_nagios::params (
@@ -308,8 +307,8 @@ $ng_ack_no_send = '0',
$ng_use_selinux_tools = true,
# httpd
$ng_required_hosts = [''],
$ng_required_ips = ['127.0.0.0/8'],
$ng_required_hosts = '',
$ng_required_ips = '127.0.0.0/8',
) {

View File

@@ -19,14 +19,12 @@ ScriptAlias /nagios/cgi-bin/ "/usr/lib64/nagios/cgi-bin/"
<IfVersion >= 2.3>
<RequireAll>
Require all granted
<% if @ng_required_hosts != '' -%>
<% @ng_required_hosts.each do |required_host| -%>
Require host <%= required_host %>
<% end end -%>
<% if @ng_required_ips != '' -%>
<% @ng_required_ips.each do |required_ips| -%>
<% unless @ng_required_hosts.empty? -%>
Require host <%= @ng_required_hosts %>
<% end -%>
<% unless @ng_required_ips.empty? -%>
Require ip <%= required_ips %>
<% end end -%>
<% end -%>
AuthName "Nagios Access"
AuthType Basic
AuthUserFile /etc/nagios/passwd
@@ -56,14 +54,12 @@ Alias /nagios "/usr/share/nagios/html"
<IfVersion >= 2.3>
<RequireAll>
Require all granted
<% if @ng_required_hosts != '' -%>
<% @ng_required_hosts.each do |required_host| -%>
Require host <%= required_host %>
<% end end -%>
<% if @ng_required_ips != '' %>
<% @ng_required_ips.each do |required_ips| -%>
<% unless @ng_required_hosts.empty? -%>
Require host <%= @ng_required_hosts %>
<% end -%>
<% unless @ng_required_ips.empty? -%>
Require ip <%= required_ips %>
<% end end -%>
<% end -%>
AuthName "Nagios Access"
AuthType Basic
AuthUserFile /etc/nagios/passwd