|
@@ -0,0 +1,40 @@
|
|
|
|
+#
|
|
|
|
+# Bloody fooking plugin doesn't do sudo correcty.
|
|
|
|
+#
|
|
|
|
+
|
|
|
|
+object CheckCommand "sudo_mailq" {
|
|
|
|
+ command = [ "sudo", PluginDir + "/check_mailq" ]
|
|
|
|
+
|
|
|
|
+ arguments = {
|
|
|
|
+ "-w" = {
|
|
|
|
+ value = "$mailq_warning$"
|
|
|
|
+ description = "Min. number of messages in queue to generate warning"
|
|
|
|
+ required = true
|
|
|
|
+ }
|
|
|
|
+ "-c" = {
|
|
|
|
+ value = "$mailq_critical$"
|
|
|
|
+ description = "Min. number of messages in queue to generate critical alert ( w < c )"
|
|
|
|
+ required = true
|
|
|
|
+ }
|
|
|
|
+ "-W" = {
|
|
|
|
+ value = "$mailq_domain_warning$"
|
|
|
|
+ description = "Min. number of messages for same domain in queue to generate warning"
|
|
|
|
+ }
|
|
|
|
+ "-C" = {
|
|
|
|
+ value = "$mailq_domain_critical$"
|
|
|
|
+ description = "Min. number of messages for same domain in queue to generate critical alert ( W < C )"
|
|
|
|
+ }
|
|
|
|
+ "-t" = {
|
|
|
|
+ value = "$mailq_timeout$"
|
|
|
|
+ description = "Plugin timeout in seconds (default = 15)"
|
|
|
|
+ }
|
|
|
|
+ "-M" = {
|
|
|
|
+ value = "$mailq_servertype$"
|
|
|
|
+ description = "[ sendmail | qmail | postfix | exim | nullmailer ] (default = autodetect)"
|
|
|
|
+ }
|
|
|
|
+ "-s" = {
|
|
|
|
+ set_if = "$mailq_sudo$"
|
|
|
|
+ description = "Use sudo for mailq command"
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+}
|