|
|
mailman-qmail.pl -- qmail alias manager for mailman.
mailman-qmail.pl
mailman-qmail.pl show
mailman-qmail.pl create listname[,listname1,listname2,...,listnameN]
mailman-qmail.pl repair listname[,listname1,listname2,...,listnameN]
mailman-qmail.pl delete listname[,listname1,listname2,...,listnameN]
mailman-qmail.pl provides a simple command-line tool for maintaining the
qmail
alias files needed to interact with
mailman, The GNU Mailing
List Manager.
mailman-qmail.pl has three distinct functions: showing lists that have all
valid qmail alias files as well as creating, or deleting qmail alias files
needed for a email distribution list.
When mailman-qmail.pl is run without any options or with unknown or
incomplete options, it displays license and usage information.
show
The show option displays a simple list of all lists that have been
configured to work with mailman. This is determined by checking to make sure that
all the alias files needed exist. For example if there is a list called
'testme' the following files would need to exist in the qmail alias
directory: '.qmail-testme', '.qmail-testme-admin', '.qmail-testme-owner',
'.qmail-testme-request'. The show option does not care about the contents
of the files - just their existence.
The output for the show option is a simple list showing all the email lists
that exist (have the proper alias files). Here is an example listing
showing the 'testme' list:
List Name
----------
+ user-list
+ testme
create listname[,listname1,listname2,...,listnameN]
The create option will setup one or more sets of alias files for a mailman email distribution
list. If you decide to create more than one distribution list you will need
to provide a comma separated list of the distribution lists with no spaces
between entries. For example to create the testme, testme-2, and testme-3
lists you would run:
mailman-qmail.pl create testme,testme-2,testme-3
After entering the above command it will go thru each list and ask to
create the required files. You will need to type 'yes' or 'no' to continue
creating or not (depending on your choice) the files. Any other response
will cause the application to ask again. Answering 'no' to any item will
not break entire creation process - just keep the single item from being
created.
repair listname[,listname1,listname2,...,listnameN]
The repair option will re-setup one or more sets of alias files for a mailman email distribution
list. If you decide to repair more than one distribution list you will need
to provide a comma separated list of the distribution lists with no spaces
between entries. For example to repair the testme, testme-2, and testme-3
lists you would run:
mailman-qmail.pl repair testme,testme-2,testme-3
After entering the above command it will go thru each list and ask to
repair the required files. You will need to type 'yes' or 'no' to continue
repairing or not (depending on your choice) the files. Any other response
will cause the application to ask again. Answering 'no' to any item will
not break entire repair process - just keep the single item from being
repaired.
delete listname[,listname1,listname2,...,listnameN]
The delete option will remove one or more sets of alias files for a mailman email distribution
list. If you decide to delete more than one distribution list you will need
to provide a comma separated list of the distribution lists with no spaces
between entries. For example to delete the testme, testme-2, and testme-3
lists you would run:
mailman-qmail.pl delete testme,testme-2,testme-3
After entering the above command it will go thru each list and ask to
delete the required files. You will need to type 'yes' or 'no' to continue
deleting or not (depending on your choice) the files. Any other response
will cause the application to ask again. Answering 'no' to any item will
not break entire deletion process - just keep the single item from being
removed.
mailman-qmail.pl is minimally configurable, the following variables can be changed.
$mailman_wrapper
The name (including path) of the mailman wrapper. By default this script
uses "/var/lib/mailman/mail/wrapper". The program was developed using
'stable' Debian GNU/Linux.
$alias_dir
This is the location that you have configured qmail to store system
wide 'dot-qmail' alias files. This location is usually
'/var/qmail/alias/'.
$qmail_prefix
The prefix used to create the email file - by default qmail uses '.qmail-'.
This should not need to be changed unless qmail changes it's standards
or you have some exotic qmail configuration. If this is updated you may
need to update the if-block in the parseQmailDir subprogram.
@list_functions
The @list_functions is a list of all functions for the list. When a new
list is being created a file for each function is created in $alias_dir.
These files are done to conform with mailman standards. Normally this list does not get
modified.
%function_override
The %function_override will override the text to be put in the alias file.
These are all optional, if left out the function listed in @list_functions
will be used as a string as well. A few defaults have been put in place,
and should not need to be modified.
If you find a bug please let me know email me at
thompson@cns.uni.edu.
Copyright (C) 2003 Aaron Thompson
thompson@cns.uni.edu
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
Foundation; either version 2 of the License, or (at your option) any later
version.
This program is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
You should have received a copy of the GNU General Public License along with
this program; if not, write to the Free Software Foundation, Inc., 59 Temple
Place - Suite 330, Boston, MA 02111-1307, USA. or visit
http://www.gnu.org/copyleft/gpl.html
Click here to view the source code online
Click here to download the script
|