]> git.donarmstrong.com Git - dsa-puppet.git/blobdiff - modules/raidmpt/manifests/init.pp
some sample rdoc
[dsa-puppet.git] / modules / raidmpt / manifests / init.pp
index 532c35d5b4d9bf360597cc1c3d2561ca94b28825..2d84af155480b153ca8233292fec1de7a21ff9a0 100644 (file)
@@ -1,21 +1,24 @@
+# = Class: raidmpt
+#
+# This class installs mpt-status and ensures the daemon is not running
+#
+# == Sample Usage:
+#
+#   include raidmpt
+#
 class raidmpt {
-    package {
-        mtp-status: ensure => installed;
-    }
 
-    file {
-        "/etc/default/mpt-statusd":
-            content =>  "# This file is under puppet control\nRUN_DAEMON=no",
-            notify  => Exec["mpt-statusd-stop"],
-            ;
-    }
-    exec {
-        "mpt-statusd-stop":
-            command => 'pidfile=/var/run/mpt-statusd.pid; ! [ -e "$pidfile" ] || /sbin/start-stop-daemon --oknodo --stop --quiet --pidfile "$pidfile"; rm -f "$pidfile"'
-            refreshonly => true,
-            ;
-    }
+       package { 'mpt-status':
+               ensure => installed
+       }
+
+       file { '/etc/default/mpt-statusd':
+               content => "# This file is under puppet control\nRUN_DAEMON=no\n",
+               notify  => Exec['mpt-statusd-stop'],
+       }
+
+       exec { 'mpt-statusd-stop':
+               command => 'pidfile=/var/run/mpt-statusd.pid; ! [ -e "$pidfile" ] || /sbin/start-stop-daemon --oknodo --stop --signal TERM --quiet --pidfile "$pidfile"; rm -f "$pidfile";  pkill -INT  -P 1 -u 0 -f "/usr/bin/daemon /etc/init.d/mpt-statusd check_mpt"',
+               refreshonly => true,
+       }
 }
-# vim:set et:
-# vim:set ts=4:
-# vim:set shiftwidth=4: