[Mailman-Users] Setting domain in URLs

Richard Barrett r.barrett at openinfo.co.uk
Tue Feb 10 02:02:28 CET 2004


On 10 Feb 2004, at 00:14, Paul Makepeace wrote:

> Je 2004-02-09 22:56:47 +0000, Richard Barrett skribis:
>> On 9 Feb 2004, at 22:39, Paul Makepeace wrote:
>>>
>>> So let's say I have (in mm_cfg.py) DEFAULT_URL_HOST = 
>>> 'foo-domain.com'
>>> and two mailing lists, foo at foo-domain.com and bar at bar-domain.com I
>>> would
>>> like http://bar-domain.com/mailman/listinfo/bar to show URLs with 
>>> bar-
>>> domain.com rather than foo-domain.com
>>>
>>
>> In that case, per the FAQ entry 4.029 that I cited, you might want to
>> say in $prefix/mm_cfg.py:
>>
>> DEFAULT_EMAIL_HOST = 'foo-domain.com'
>> DEFAULT_URL_HOST = 'foo-domain.com'
>> VIRTUAL_HOSTS.clear()
>> add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
>> add_virtualhost('bar-domain.com', 'bar-domain.com')
>
> Ah, OK - thanks Richard, this seems to work OK. It's a bit frustrating 
> &
> long-winded to have to add this for every list but hey.

Not every list, every host has to be configured with an 
add_virtualhost; and for most of us there is a many-one mapping of 
lists to hosts.

btw: did I mention:

1.  that all that all virtual hosts being serviced by a given MM 
installation share a common listname namespace; you cannot presently 
have list1 at foo-domain.com and list1 at bar-domain.com as separate lists 
with plain vanilla Mailman

2. You can create lists directly on a given virtual host once they are 
set up, without the need to use fix_url. See, and read carefully, the 
output from running $prefix/bin/new_list -h

>
> There's reference to 'web_page_url' in the fix_url.py script and
> outputted config (config_list -o). This sounds exactly what I'd like to
> edit! Yet it isn't configurable directly. Is there some architectural
> reason why not?
>
>> and use fix_url to set the foo-domain.com lists to use foo-domain.com
>
> This script bills itself to "set the web_page_url and host_name
> attributes of the list to the values found."
>
> But web_page_url is not a configurable variable?! Insofar as I even
> tried with config_list -i and it complained that web_page_url wasn't
> restorable.

It is not architectural but editing a list's web_page_url was removed 
from the list admin web GUI with the introduction of MM 2.1.x. I 
believe the reason was that list admins were prone to editing in wrong 
values on the GUI which when applied made the web interface for the 
list unavailable with the command line being the only way to then 
recover the situation. In a hosting environment this creates a support 
problem etc, etc: I believe that was why MM's owner Barry Warsaw made 
the change from the previous situation with MM 2.0.x.

I have never tried to use config_list to change the web_page_url list 
config variable. I am a little surprised it does not work but fix_url 
can be run from the shell if you have to do a bunch of lists; a simple 
shell script to iterate over a list of listnames and run fix_url for a 
given host against each is no big deal.

>
> Thanks for your help,
> Paul (eyes starting to droop & glaze over at this point :-)
>
> -- 
> Paul Makepeace ................................  
> http://paulm.com/ecademy
>
> "What is a collonic irrigation? Samba!"
>    -- http://paulm.com/toys/surrealism/
>





More information about the Mailman-Users mailing list