[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[monit] Patch: $DESCRIPTION parsed to the "exec" action?

From: Morten Bressendorff Schmidt
Subject: [monit] Patch: $DESCRIPTION parsed to the "exec" action?
Date: Wed, 09 Jan 2008 12:51:20 +0100


I posted yesterday... I didn't get any mails, except digest, så I have to
start a new therad. Sorry  'bout that
Thanks to the people who helped!!!

I think I kind of created a patch myself (for the Debian sources of
version 4.8.1-2.1 I believe)
Hope it works for you people who might need the environment variable
MONIT_DESCRIPTION... I attached the patch, and I show it here:

--- ../spawn_orig.c     2008-01-09 12:11:43.000000000 +0100
+++ spawn.c     2008-01-09 12:19:09.000000000 +0100
@@ -269,6 +269,9 @@
   snprintf(buf, STRLEN, "MONIT_EVENT=%s", event?event:"No Event");
   push_monit_environment(buf, e);

+  snprintf(buf, STRLEN, "MONIT_DESCRIPTION=%s", s->eventlist->message);
+  push_monit_environment(buf, e);
   if (s->type == TYPE_PROCESS) {
     snprintf(buf, STRLEN, "MONIT_PROCESS_PID=%d",
     push_monit_environment(buf, e);

Best regards

Attachment: monit_spawn.c_MONIT_DESCRIPTION_env.patch
Description: Binary data

reply via email to

[Prev in Thread] Current Thread [Next in Thread]