Hi,

with help and motivation from Odhiambo Washington, the
router/transport has today been re-worked to also handle queues with
spaces.

- The "does this queue exist" now ignores disabled lists
- The queue name to use is now pulled from the mysql database instead
  of the e-mail address, allowing queues to have a name different from
  the e-mail address, and allowing queues to have a name with spaces.

If you don't want people to see your mysql database password, you'd
need to set /etc/exim4/conf.d/main/10_request-tracker3 to an
appropriate mode, and set CFILEMODE to the same mode in
/etc/exim4/update-exim4.conf.conf

(1)  /etc/exim4/conf.d/main/10_request-tracker3
QUEUENAME_QUERY   = \
                  SELECT Name FROM Queues WHERE \
                  CorrespondAddress = '${quote_mysql:[EMAIL 
PROTECTED]:$domain}' \
                  AND Disabled = '0'


hide mysql_servers = $DBHOST/$DBNAME/$DBUSER/$DBPASSWORD

domainlist rt3_domains = $DOMAINLIST

RT3_URL = http://$HOSTNAME/rt/


(2) /etc/exim4/conf.d/transport/30_request-tracker3
request_tracker3_pipe:
  debug_print = "T: request_tracker3_pipe for [EMAIL PROTECTED]"
  driver = pipe
  return_fail_output
  allow_commands = /usr/bin/rt-mailgate

(3) /etc/exim4/conf.d/router/310_request_tracker3
request_tracker3:
  debug_print = "R: request_tracker3 for \
                    [EMAIL PROTECTED] \
                    (calling ${substr_1:${if eq{$local_part_suffix}{}\
                                       {-correspond}\
                                       {$local_part_suffix}}})"
  driver = redirect
  domains = +rt3_domains
  local_parts = mysql; QUEUENAME_QUERY
  local_part_suffix = -comment
  local_part_suffix_optional
  pipe_transport = request_tracker3_pipe
  data = "|/usr/bin/rt-mailgate \
           --queue \"${lookup mysql{QUEUENAME_QUERY}}\" \
           --action ${substr_1:${if eq{$local_part_suffix}{}\
                                        {-correspond}\
                                        {$local_part_suffix}}} \
           --url RT3_URL"
  user = www-data

I don't particularly like the idea of running the mailgate process as
www-data, but since the bulk of rt runs as www-data anyway, there is
probably not a way to get around this.

If there are more suffixes supported/needed than -comment, these could
be added to the local_part_suffix list, colon separated.

This configuration has been tested by Odhiambo Washington on a
non-Debian system. I am currently not in a position do to any tests on
my own.

There are probably security things missing - but it gets the job done
in a better way than the exim 3 configuration given in
INSTALL.Debian.gz.

Please consider shipping this configuration with Mailman, either as
example or productive file in the given directory.

Greetings
Marc

-- 
[EMAIL PROTECTED]              syscovery network services GmbH
Dipl.-Inform.                                    Weinheimer Stra�e 68
Gesch�ftsf�hrer                                      D-68309 Mannheim
Tel: +49 [0] 621 71768 57                   http://www.syscovery.com/


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to