Compare commits

..

5 Commits

Author SHA1 Message Date
Jenkins
3335b44713 Merge branch 'jenkins-build-14' into 'master'
Auto-merge for build 14

See merge request puppet/confdroid_ssh!14
2026-04-09 15:01:54 +02:00
Jenkins Server
fbdc21d72f Recommit for updates in build 14 2026-04-09 14:57:52 +02:00
Jenkins Server
dd9fc23d28 Merge remote-tracking branch 'origin/master' into jenkins-build-14 2026-04-09 14:56:56 +02:00
cf1415ceac OP#561 try new fw settings 2026-04-09 14:56:37 +02:00
Jenkins
a2a3f1c862 Merge branch 'jenkins-build-13' into 'master'
Auto-merge for build 13

See merge request puppet/confdroid_ssh!13
2026-04-09 12:33:33 +00:00
2 changed files with 27 additions and 33 deletions

View File

@@ -120,9 +120,7 @@
22
23
24
25
26
27</pre>
25</pre>
</td>
<td>
<pre class="code"><span class="info file"># File 'manifests/firewall/iptables.pp', line 6</span>
@@ -130,23 +128,21 @@
class confdroid_ssh::firewall::iptables (
) inherits confdroid_ssh::params {
if $ssh_use_firewall == true {
firewall { &quot;${ssh_fw_order}${ssh_fw_port} allow SSH on port ${ssh_fw_port}&quot;:
ensure =&gt; &#39;present&#39;,
proto =&gt; &#39;tcp&#39;,
source =&gt; $ssh_source_range,
dport =&gt; $ssh_fw_port,
jump =&gt; &#39;accept&#39;,
case $ssh_use_firewall {
true, &#39;true&#39;, &#39;yes&#39;, &#39;1&#39;: {
$ssh_fw_ensure = &#39;present&#39;
}
default: {
$ssh_fw_ensure = &#39;absent&#39;
}
}
if $ssh_use_firewall == false {
firewall { &quot;${ssh_fw_order}${ssh_fw_port} remove SSH on port ${ssh_fw_port}&quot;:
ensure =&gt; &#39;absent&#39;,
proto =&gt; &#39;tcp&#39;,
source =&gt; $ssh_source_range,
dport =&gt; $ssh_fw_port,
jump =&gt; &#39;accept&#39;,
}
firewall { &quot;${ssh_fw_order}${ssh_fw_port} allow SSH on port ${ssh_fw_port}&quot;:
ensure =&gt; $ssh_fw_ensure,
proto =&gt; &#39;tcp&#39;,
source =&gt; $ssh_source_range,
dport =&gt; $ssh_fw_port,
jump =&gt; &#39;accept&#39;,
}
}</pre>
</td>

View File

@@ -6,22 +6,20 @@
class confdroid_ssh::firewall::iptables (
) inherits confdroid_ssh::params {
if $ssh_use_firewall == true {
firewall { "${ssh_fw_order}${ssh_fw_port} allow SSH on port ${ssh_fw_port}":
ensure => 'present',
proto => 'tcp',
source => $ssh_source_range,
dport => $ssh_fw_port,
jump => 'accept',
case $ssh_use_firewall {
true, 'true', 'yes', '1': {
$ssh_fw_ensure = 'present'
}
default: {
$ssh_fw_ensure = 'absent'
}
}
if $ssh_use_firewall == false {
firewall { "${ssh_fw_order}${ssh_fw_port} remove SSH on port ${ssh_fw_port}":
ensure => 'absent',
proto => 'tcp',
source => $ssh_source_range,
dport => $ssh_fw_port,
jump => 'accept',
}
firewall { "${ssh_fw_order}${ssh_fw_port} allow SSH on port ${ssh_fw_port}":
ensure => $ssh_fw_ensure,
proto => 'tcp',
source => $ssh_source_range,
dport => $ssh_fw_port,
jump => 'accept',
}
}