[Mailman-Developers] WN Web server support

Thomas Wouters thomas@xs4all.net
Sat, 29 Jul 2000 16:16:27 +0200


On Fri, Jul 28, 2000 at 02:57:40PM -0500, Roy C. Bixler wrote:


> If, as I suspect, no one has tackled this yet, I don't think it would be
> very hard.  What makes WN different from other Web servers is that it
> requires a database (an 'index.cache' file) in each directory enumerating
> which files can be served.  This poses a problem for the archive
> directories where 'index.cache' has to be updated each time a posting is
> added to the archive.  A quick and dirty way to do this is with a 'wndex
> -a' command (i.e. creates an 'index.cache' file which gives permission for
> all current files in this directory to be served) executed from a 'cron'
> job. Even better, could this be done in Mailman/Archive/HyperArch.py?  
> The last line of the HyperArch::Write_TOC() method would be:
> 
> os.system("wndex -a -d " + self.basedir)

> ('-d' argument specifies directory to create 'index.cache' file.)

> Comments?  (Yes, I know I could take the easy way out and change my Web
> server, but WN support in Mailman would interest others as well.)

Actualy, I would suggest making it a site-configuration option: something in
mm_cfg.py that can be set by the site admin, and is an empty string in
Defaults.py. That means that the site admin can customize it to fit the
needs of the site (webserver or whatever.) You probably need to do something
like this:

if mm_cfg.POST_ARCHIVE:
	infodict = {
		'basedir': self.basedir,
		'listname': ...
		'listaddr': ...
		<... etc>
	}

	os.system(mm_cfg.POST_ARCHIVE % infodict)

It should be a site-admin job and not a list admin job, for the obvious
security issues. Exactly what information to include in the infodict is
subject to discussion, but I think starting with some of the information at
hand is fine. More stuff can be added later, and much more complicated stuff
should be handled by an external archiver instead, anyway.

-- 
Thomas Wouters <thomas@xs4all.net>

Hi! I'm a .signature virus! copy me into your .signature file to help me spread!