[Mailman-Users] Problem with listinfo and advertised in global virtual host setup(I did my homework)

Steve Werby steve-lists at befriend.com
Tue Feb 4 21:19:33 CET 2003


"Vivek Khera" <khera at kcilink.com> wrote:
> >>>>> "SW" == Steve Werby <steve-lists at befriend.com> writes:
>
> SW> I recently installed Mailman 2.1 on a machine running Apache 1.3.20.
> SW> Mailman is installed in a central location and made available to all
virtual
> SW> sites via an Apache ScriptAlias directive.  The lists function
properly and
> SW> all are accessible, but are not listed on the listinfo page even
though
>
> I discovered the hard way that the vhost under which the list will be
> displayed depends on the url set in the list.  unfortunately there's
> no way to change that URL from the web.  you need to use the
> bin/uri_fix.py (or something like that) script to set the url
> correctly.  Then it finds your site based on the vhost.

Thanks  Vivek.  That got me on the right track.  For the benefit of others,
here's what I did in order to setup lists @foo.bar, make the advertised
lists visible at host.foo.bar and prevent them from being visible at
host.bar.com (or any other hostname).  They can still be accessed through
host.bar.com (obviously), but they're just not listed which is all that's
important to me.

I setup a global Mailman install for the server using the Apache Alias
directive (Apache 1.3.x).

1. Setup lists in Sendmail using @foo.bar.
2. Run ./bin/withlist -l -r fix_url <listname> --urlhost=host.foo.bar
3. Edit Mailman/mm_cfg.py and add the following so Mailman's address shows
as mailman @foo.bar, not @host.foo.bar:

def add_virtualhost(urlhost, emailhost=None):
   DOT = '.'
   if emailhost is None:
        emailhost = DOT.join(urlhost.split(DOT)[1:])
   VIRTUAL_HOSTS[urlhost.lower()] = emailhost.lower()

add_virtualhost( 'host.foo.bar', 'foo.bar' )

I am pretty sure I found the above code in the source tarball (I
copied/pasted it a few days ago).  I program in several languages, but not
Python...yet.  There may be a better/different way, but this worked for me.
All is good.  YMMV.

--
Steve Werby
President, Befriend Internet Services LLC
http://www.befriend.com/







More information about the Mailman-Users mailing list