]> gitweb.fluxo.info Git - puppet-sshd.git/commitdiff
check ssh with nagios
authormh <mh@d66ca3ae-40d7-4aa7-90d4-87d79ca94279>
Fri, 7 Nov 2008 20:19:31 +0000 (20:19 +0000)
committermh <mh@d66ca3ae-40d7-4aa7-90d4-87d79ca94279>
Fri, 7 Nov 2008 20:19:31 +0000 (20:19 +0000)
git-svn-id: https://svn/ipuppet/trunk/modules/sshd@2672 d66ca3ae-40d7-4aa7-90d4-87d79ca94279

manifests/init.pp

index 1c7a3e8bd3d43717e72dbc505ffc3730dbed1079..c7f6bff30b20ab2306b6ddb464bc67fbf3149fa2 100644 (file)
@@ -228,6 +228,12 @@ class sshd::base {
         hasstatus => true,
                require => File[sshd_config],
     }
+    if $use_nagios {
+        case $nagios_check_ssh {
+            'false': { info("We don't do nagioschecks for ssh on ${fqdn}" ) }
+            default: { nagios::service{ "ssh_port_${sshd_port}": check_command => "ssh_port!$sshd_port" } }
+        }
+    }
 }
 
 class sshd::linux inherits sshd::base {