qmail-autoresponder-mysql − Produce automatic responses with qmail
qmail-autoresponder-mysql [ −cLNqT ] [ -O NAME[=VALUE] ] [ -n NUM ] [ -s STR ] [ -t TIME ] USERNAME DOMAIN [ TABLE_PREFIX ]
qmail-autoresponder-mysql sends an automatically-generated message in response to an incoming message. By default, it limits the number of responses it sends to a maximum of one message per hour per sender. It will not respond to any known mailing list, nor will it respond to either bounces or loops.
The USERNAME and DOMAIN arguments are used to select which autoresponder to use from the MySQL database. If a record in the autoresponder table matches the username and domain, the program purges old records for that autoresponder from the response table and then counts the remaining responses listed there. A record is then added to that table indicating if a response was sent or not. If a table named log exists, the same record is added to it as well. The log table is never automatically pruned.
If a TABLE_PREFIX argument is given, all table names are prefixed with that string. For example, if TABLE_PREFIX is q_ then the tables used are q_autoresponder and q_response. This can be used to allow these tables to co-exist with tables for other programs in the same database.
See the man page for qmail-autoresponder(1) for more details on options and general autoresponder behavior.
qmail-autoresponder-mysql supports options specified on the command line and as fields in the autoresponder table. Option fields are named opt_OPTION in the database, and override options set on the command line. See the man page for qmail-autoresponder(1) for a full list of options.
Typical usage in a .qmail-default file would be as follows:
|qmail-autoresponder-mysql -- "$EXT" "$HOST"
DTLINE |
qmail-autoresponder-mysql searches for this line (generated by qmail-local) in the input and bounces the message if it is present (which indicates a mail loop). It then adds the line to the output. |
MYSQL_DB
MYSQL_HOST
MYSQL_PASS
MYSQL_SOCKET
MYSQL_USER
These set the default parameters for the MySQL database connection. If not set, qmail-autoresponder-mysql uses the defaults in the qmail-autoresponder group in the MySQL option file.
SENDER |
This contains the envelope sender address and is used as the address to send the reply to. |
qmail-autoresonder(1)