From 868c161d3d31cc1f9739876e1c2f34e3efe2af05 Mon Sep 17 00:00:00 2001 From: Jonas Smedegaard Date: Wed, 18 Oct 2006 12:00:32 +0000 Subject: Much improved intro text. --- localmkpostfixvirtual | 68 +++++++++++++++++++++++++++++++++++++-------------- 1 file changed, 50 insertions(+), 18 deletions(-) (limited to 'localmkpostfixvirtual') diff --git a/localmkpostfixvirtual b/localmkpostfixvirtual index a4b98d8..13c35e2 100755 --- a/localmkpostfixvirtual +++ b/localmkpostfixvirtual @@ -3,36 +3,68 @@ # /usr/local/sbin/localmkpostfixvirtual # Copyright 2001-2006 Jonas Smedegaard # -# $Id: localmkpostfixvirtual,v 1.31 2006-08-22 23:25:23 jonas Exp $ +# $Id: localmkpostfixvirtual,v 1.32 2006-10-18 12:00:32 jonas Exp $ # # Generate virtual file for postfix # -# Hints are stored in the "Other" field (using chfn). +# This script provides a poor-man's email ISP tool using the standard +# Unix users/groups database (with generic getent lookups, supporting +# smooth upgrades to LDAP or other enterprise systems supporting the +# libc Name Service Switch. # -# Each user should have space-separated hints like this: -# "mailname1@ mailname2@mailgroup1 mailname3@mailgroup2 mailname4@maildomain7". # -# The user of each mailgroup should have hints like "@domain1 @domain2" -# for each hosted maildomain. +# Email domains +# ------------- # -# Generate virtual file like this: +# A system group is needed to locate email domains: # -# # ( cd /etc/postfix && localmkpostfixvirtual > virtual.new && diff virtual virtual.new ) +# # addgroup --system maildomains # -# ..and if the changes are correct, activate the new virtual file: # -# # ( cd /etc/postfix && mv virtual.new virtual && postmap virtual ) +# Each domain (or group of syncronously maintained domains) needs a +# virtual user, added to that central group: # -# Optional: Several mailgroups can be tied together (when amount of hints -# exceeds the limit of the "Other" field: List them all in -# "Office" or "roomnumber" field of primary mailgroup (include the -# primary mailgroup itself!). +# # adduser --system --no-create-home --group --disabled-password abcde # -# Optional: root can have hints like "postmaster@ hostmaster@ support@" -# for default accounts tied to the sysadmin (default: "postmaster@"). +# # adduser abcde maildomains # -# Suggestion: Add mailgroup users like this: -# adduser --system --no-create-home --group --disabled-password +# In the "Other" field of the GECOS info, the virtual user accounts has +# hint(s) on the email domains tied to that domain: +# +# # usermod -c "@abc.com @cde.org" abcde +# +# The GECOS info has limited space. A domain group can span multiple +# virtual accounts by mentioning the secondary account names in the +# group field of the main virtual account. +# "Office" or "roomnumber" field of the primary mailgroup (include the +# primary mailgroup itself too, if using this filed at all!). +# +# +# Email addresses +# --------------- +# +# In the "Other" field of the GECOS info, real user accounts has hint(s) +# on the email userparts tied to that user: +# +# # usermod -c "db@ dbowie@abcde +@xyz" david +# +# +# Suggestion: Add postmaster-specific hints to the root account +# (default: "postmaster@"): +# +# # usermod -c "postmaster@ hostmaster@ support@" root +# +# +# Postfix lookup tables +# --------------------- +# +# Lookup table for postfix is generated like this: +# +# # localmaildomaincreate +# +# ..and if satisified, apply the new file to the running system: +# +# # localmaildomainupdate # use strict; -- cgit v1.2.3