[Mailman-Developers] small suggestion

Mark Sapiro mark at msapiro.net
Sat Jun 26 01:25:28 CEST 2010

On 6/25/2010 1:54 PM, Kent Mein wrote:
> Hi I just have a small suggestion/patch.
> In Mailman/Utils.py in the function get_site_email
> I think it makes more sense to change these two lines:
>         return '%s@%s' % (mm_cfg.MAILMAN_SITE_LIST, hostname)
>     return '%s-%s@%s' % (mm_cfg.MAILMAN_SITE_LIST, extra, hostname)
> to this:
>         return '%s@%s' % (mm_cfg.MAILMAN_SITE_LIST, mm_cfg.DEFAULT_EMAIL_HOST)
>     return '%s-%s@%s' % (mm_cfg.MAILMAN_SITE_LIST, extra, mm_cfg.DEFAULT_EMAIL_HOST)
> chances are more likely you have the MAILMAN_SITE_LIST setup on your
> 	emailserver not on your webhost.  (We've had to tweak it here so
> 	things work)

If your VIRTUAL_HOSTS dictionary (add_virtualhost() directives) is
properly configured, hostname in the above code is the email host
corresponding to the current web host, not the web host itself. Thus,
the address has (or should have) an appropriate email domain.

There is still an issue in that the address exposed for the site list on
the admin and listinfo overview pages has the email domain for the
current virtual host rather than DEFAULT_EMAIL_HOST, and this may
require an additional virtual mapping in the MTA in order to work, but
changing the domain is not the answer as some service provider type
sites would not want to expose DEFAULT_EMAIL_HOST to someone visiting
the listinfo overview for a virtual domain.

Mark Sapiro <mark at msapiro.net>        The highway is for gamblers,
San Francisco Bay Area, California    better use your sense - B. Dylan

More information about the Mailman-Developers mailing list