summaryrefslogtreecommitdiffstats
path: root/modules/fail2ban/manifests
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2018-11-13 00:19:06 -0500
committerJesse Luehrs <doy@tozt.net>2018-11-13 00:19:06 -0500
commitbf33ac997636c4b6c199cfff1e171ffaff437c91 (patch)
tree2f3d94f0ad3fddde69fec83c4d65356d60dea479 /modules/fail2ban/manifests
parentb5fe67cdda8f05ffe814a923b1a69f7169b9db5c (diff)
downloadpuppet-tozt-bf33ac997636c4b6c199cfff1e171ffaff437c91.tar.gz
puppet-tozt-bf33ac997636c4b6c199cfff1e171ffaff437c91.zip
actually, let's make this shared again
Diffstat (limited to 'modules/fail2ban/manifests')
-rw-r--r--modules/fail2ban/manifests/init.pp21
1 files changed, 21 insertions, 0 deletions
diff --git a/modules/fail2ban/manifests/init.pp b/modules/fail2ban/manifests/init.pp
new file mode 100644
index 0000000..5ca6483
--- /dev/null
+++ b/modules/fail2ban/manifests/init.pp
@@ -0,0 +1,21 @@
+class fail2ban {
+ package { "fail2ban":
+ ensure => installed;
+ }
+
+ file {
+ "/etc/fail2ban/jail.local":
+ source => "puppet:///modules/fail2ban/jail.local",
+ notify => Service["fail2ban"],
+ require => Package["fail2ban"];
+ }
+
+ service { "fail2ban":
+ ensure => running,
+ enable => true,
+ require => [
+ File["/etc/fail2ban/jail.local"],
+ Package["fail2ban"],
+ ];
+ }
+}