|
|
5c2a97 |
# -*- python -*-
|
|
|
5c2a97 |
|
|
|
5c2a97 |
# Copyright (C) 1998,1999,2000,2001,2002 by the Free Software Foundation, Inc.
|
|
|
5c2a97 |
#
|
|
|
5c2a97 |
# This program is free software; you can redistribute it and/or
|
|
|
5c2a97 |
# modify it under the terms of the GNU General Public License
|
|
|
5c2a97 |
# as published by the Free Software Foundation; either version 2
|
|
|
5c2a97 |
# of the License, or (at your option) any later version.
|
|
|
5c2a97 |
#
|
|
|
5c2a97 |
# This program is distributed in the hope that it will be useful,
|
|
|
5c2a97 |
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
5c2a97 |
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
5c2a97 |
# GNU General Public License for more details.
|
|
|
5c2a97 |
#
|
|
|
5c2a97 |
# You should have received a copy of the GNU General Public License
|
|
|
5c2a97 |
# along with this program; if not, write to the Free Software
|
|
|
5c2a97 |
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|
|
5c2a97 |
|
|
|
5c2a97 |
"""This module contains your site-specific settings.
|
|
|
5c2a97 |
|
|
|
5c2a97 |
From a brand new distribution it should be copied to mm_cfg.py. If you
|
|
|
5c2a97 |
already have an mm_cfg.py, be careful to add in only the new settings you
|
|
|
5c2a97 |
want. Mailman's installation procedure will never overwrite your mm_cfg.py
|
|
|
5c2a97 |
file.
|
|
|
5c2a97 |
|
|
|
5c2a97 |
The complete set of distributed defaults, with documentation, are in the file
|
|
|
5c2a97 |
Defaults.py. In mm_cfg.py, override only those you want to change, after the
|
|
|
5c2a97 |
|
|
|
5c2a97 |
from Defaults import *
|
|
|
5c2a97 |
|
|
|
5c2a97 |
line (see below).
|
|
|
5c2a97 |
|
|
|
5c2a97 |
Note that these are just default settings; many can be overridden via the
|
|
|
5c2a97 |
administrator and user interfaces on a per-list or per-user basis.
|
|
|
5c2a97 |
|
|
|
5c2a97 |
"""
|
|
|
5c2a97 |
|
|
|
5c2a97 |
###############################################
|
|
|
5c2a97 |
# Here's where we get the distributed defaults.
|
|
|
5c2a97 |
|
|
|
5c2a97 |
from Defaults import *
|
|
|
5c2a97 |
import pwd, grp
|
|
|
5c2a97 |
|
|
|
5c2a97 |
##################################################
|
|
|
5c2a97 |
# Put YOUR site-specific settings below this line.
|
|
|
5c2a97 |
|
|
|
5c2a97 |
#ATTENTION: when you use SELinux, mailman might not
|
|
|
5c2a97 |
#be able to recompile the configuration file
|
|
|
5c2a97 |
#due to policy settings. If this is the case,
|
|
|
5c2a97 |
#please run (as root) the supplied "mailman-update-cfg" script
|
|
|
5c2a97 |
|
|
|
5c2a97 |
##############################################################
|
|
|
5c2a97 |
# Here's where we override shipped defaults with settings #
|
|
|
5c2a97 |
# suitable for the RPM package. #
|
|
|
5c2a97 |
MAILMAN_UID = pwd.getpwnam('mailman')[2]
|
|
|
5c2a97 |
MAILMAN_GID = grp.getgrnam('mailman')[2]
|
|
|
5c2a97 |
|
|
|
5c2a97 |
##############################################################
|
|
|
5c2a97 |
# Set URL and email domain names #
|
|
|
5c2a97 |
#
|
|
|
5c2a97 |
# Mailman needs to know about (at least) two fully-qualified domain
|
|
|
5c2a97 |
# names (fqdn)
|
|
|
5c2a97 |
#
|
|
|
5c2a97 |
# 1) the hostname used in your urls (DEFAULT_URL_HOST)
|
|
|
5c2a97 |
# 2) the hostname used in email addresses for your domain (DEFAULT_EMAIL_HOST)
|
|
|
5c2a97 |
#
|
|
|
5c2a97 |
# For example, if people visit your Mailman system with
|
|
|
5c2a97 |
# "http://www.dom.ain/mailman" then your url fqdn is "www.dom.ain",
|
|
|
5c2a97 |
# and if people send mail to your system via "yourlist@dom.ain" then
|
|
|
5c2a97 |
# your email fqdn is "dom.ain". DEFAULT_URL_HOST controls the former,
|
|
|
5c2a97 |
# and DEFAULT_EMAIL_HOST controls the latter. Mailman also needs to
|
|
|
5c2a97 |
# know how to map from one to the other (this is especially important
|
|
|
5c2a97 |
# if you're running with virtual domains). You use
|
|
|
5c2a97 |
# "add_virtualhost(urlfqdn, emailfqdn)" to add new mappings.
|
|
|
5c2a97 |
|
|
|
5c2a97 |
# Default to using the FQDN of machine mailman is running on.
|
|
|
5c2a97 |
# If this is not correct for your installation delete the following 5
|
|
|
5c2a97 |
# lines that acquire the FQDN and manually edit the hosts instead.
|
|
|
5c2a97 |
|
|
|
5c2a97 |
from socket import *
|
|
|
5c2a97 |
try:
|
|
|
5c2a97 |
fqdn = getfqdn()
|
|
|
5c2a97 |
except:
|
|
|
5c2a97 |
fqdn = 'mm_cfg_has_unknown_host_domains'
|
|
|
5c2a97 |
|
|
|
5c2a97 |
DEFAULT_URL_HOST = fqdn
|
|
|
5c2a97 |
DEFAULT_EMAIL_HOST = fqdn
|
|
|
5c2a97 |
|
|
|
5c2a97 |
# Because we've overriden the virtual hosts above add_virtualhost
|
|
|
5c2a97 |
# MUST be called after they have been defined.
|
|
|
5c2a97 |
|
|
|
5c2a97 |
add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
|
|
|
5c2a97 |
|
|
|
5c2a97 |
|
|
|
5c2a97 |
##############################################################
|
|
|
5c2a97 |
# Put YOUR site-specific configuration below, in mm_cfg.py . #
|
|
|
5c2a97 |
# See Defaults.py for explanations of the values. #
|
|
|
5c2a97 |
|
|
|
5c2a97 |
# Note - if you're looking for something that is imported from mm_cfg, but you
|
|
|
5c2a97 |
# didn't find it above, it's probably in Defaults.py.
|