From LedHed's Wiki
| Line 1: | Line 1: | ||
| + | Reference: http://linox.be/index.php/2005/07/13/44/#comment-52886 | ||
== Creating the Vacation User/Group == | == Creating the Vacation User/Group == | ||
| Line 16: | Line 17: | ||
== Postfix Intigration == | == Postfix Intigration == | ||
| + | |||
| + | === Master.cf === | ||
Edit /etc/postfix/master.cf | Edit /etc/postfix/master.cf | ||
Add these lines at the bottom. | Add these lines at the bottom. | ||
| Line 22: | Line 25: | ||
vacation unix - n n - - pipe | vacation unix - n n - - pipe | ||
flags=Rhu user=vacation argv=/var/spool/vacation/vacation.pl | flags=Rhu user=vacation argv=/var/spool/vacation/vacation.pl | ||
| + | |||
| + | === Transport Map === | ||
| + | Create a transport map | ||
| + | touch /etc/postfix/transport_maps.cf | ||
| + | Edit transport_maps.cf and add these lines to it. Substitute your information where needed. | ||
| + | user = postfix | ||
| + | password = ******** | ||
| + | hosts = localhost | ||
| + | dbname = postfix | ||
| + | query = SELECT transport FROM transport_table WHERE domain='%s' | ||
| + | Edit main.cf and add/change: | ||
| + | transport_maps = mysql:/etc/postfix/transport_maps.cf | ||
| + | |||
| + | |||
| + | == MySQL == | ||
| + | |||
| + | ''Down and Dirty'' | ||
| + | |||
| + | Create a table called 'transport' | ||
| + | Create 'domain' field varchar(255) and PKEY | ||
| + | Create 'transport' field varchr(255) | ||
| + | |||
| + | Add your FQDN in the 'domain' field and 'virtual:' in the 'transport' field. | ||
| + | Add 'autoreply.yourdomain.com in the 'domain' field and 'vacation' in the 'transport' field. | ||
| + | it should look something like this: | ||
| + | +----------------------+----------+ | ||
| + | | domain | transport| | ||
| + | +----------------------+----------+ | ||
| + | | domain.tld | virtual: | | ||
| + | | autoreply.domain.tld | vacation | | ||
| + | +----------------------+----------+ | ||
| + | '''More to come''' | ||
[[Category:PostfixAdmin]] | [[Category:PostfixAdmin]] | ||
Revision as of 01:01, 3 April 2007
Reference: http://linox.be/index.php/2005/07/13/44/#comment-52886
Contents
Creating the Vacation User/Group
groupadd vacation useradd -s/sbin/nologin -d/nonexistent -g vacation vacation
See [User Management] for more information on creating users in linux
Creating Directories
mkdir -p /var/spool/vacation cp /tmp/postfixadmin-2.1.0/VIRTUAL_VACATION/vacation.pl /var/spool/vacation chown -R vacation.vacation /var/spool/vacation chmod -R 700 /var/spool/vacation
Postfix Intigration
Master.cf
Edit /etc/postfix/master.cf Add these lines at the bottom.
### Postfix Admin Vacation Message vacation unix - n n - - pipe flags=Rhu user=vacation argv=/var/spool/vacation/vacation.pl
Transport Map
Create a transport map
touch /etc/postfix/transport_maps.cf
Edit transport_maps.cf and add these lines to it. Substitute your information where needed.
user = postfix password = ******** hosts = localhost dbname = postfix query = SELECT transport FROM transport_table WHERE domain='%s'
Edit main.cf and add/change:
transport_maps = mysql:/etc/postfix/transport_maps.cf
MySQL
Down and Dirty
Create a table called 'transport' Create 'domain' field varchar(255) and PKEY Create 'transport' field varchr(255)
Add your FQDN in the 'domain' field and 'virtual:' in the 'transport' field. Add 'autoreply.yourdomain.com in the 'domain' field and 'vacation' in the 'transport' field. it should look something like this:
+----------------------+----------+ | domain | transport| +----------------------+----------+ | domain.tld | virtual: | | autoreply.domain.tld | vacation | +----------------------+----------+
More to come