[rt-users] rt3 enhanced mailgate?

Ruediger Riediger ruediger.riediger at sun.com
Tue Nov 9 03:53:38 EST 2004


brianBOFH wrote:
> Do any of you have an enhanced rt3 mailgate?  We were using the rt2
> version fairly heavily (to auto-assign Owner based on body content -
> RT-Owner: user)

beside the comment about the Scrips (has the big advantage that web 
submissions are handled as well :-) we have added one option to the 
mailgate to respond back the ticket number so procmail (or mail 
dispatcher) can do nifty stuff with it (e.g. link the message-id to the 
incident, so follow-ups with a reference, or in-reply header are filled 
correctly without the ticket number in the subject).

from procmailrc:

REQ|=rt-mailgate <usual options> --ticket



and the diff:

*** rt-mailgate.ORIG
--- rt-mailgate
***************
*** 367,373 ****
   use constant EX_TEMPFAIL => 75;

   my %opts;
! GetOptions( \%opts, "queue=s", "action=s", "url=s", "jar=s", "help", 
"debug", "extension=s" );

   if ( $opts{help} ) {
       require Pod::Usage;
--- 367,373 ----
   use constant EX_TEMPFAIL => 75;

   my %opts;
! GetOptions( \%opts, "queue=s", "action=s", "url=s", "jar=s", "ticket", 
"help", "debug", "extension=s" );

   if ( $opts{help} ) {
       require Pod::Usage;
***************
*** 408,413 ****
--- 408,414 ----
   check_failure($r);

   my $content = $r->content;
+ print $1 ."\n" if ( $opts{ticket} && $content =~ 
/^Ticket:\s+(\d+)\s*$/m );
   warn $content if ($opts{debug});

   if ( $content !~ /^(ok|not ok)/ ) {



Best regards,

	Ruediger Riediger

-- 
Dr. Ruediger Riediger                              Sun Microsystems GmbH
NSG - SunCERT                                             Komturstr. 18a
mailto:Ruediger.Riediger at Sun.com                          D-12099 Berlin
------------------------------------------------------------------------
NOTICE:  This email message is for the sole use of the intended
recipient(s) and may contain confidential and privileged information.
Any unauthorized review, use, disclosure or distribution is prohibited.
If you are not the intended recipient, please contact the sender by
reply email and destroy all copies of the original message.
------------------------------------------------------------------------
PGP 2048RSA/0x2C5020E9          964C E189 0FF0 8882  2BAB 65E2 6912 1FF2
------------------------------------------------------------------------



More information about the rt-users mailing list