Virtual Domains Redux (w proposal)
AKA, "The Perennial Issue" (TPI)
I've been looking at this for a while; I've scanned the archives; and
I've perused the code (well a chunk of it anyway).
I realize that mailman _sort of_ supports virtual domains, but
doesn't _really_ support virtual domains.
As I look at the situation from the perspective of a sysadmin or ISP,
there are two aspects that really bother me:
- comingling of data from separate virtual domains
- ''site'' password shared between virtual domains
From my perusals I think what I'm really asking for is a per-domain
assignment of VAR_PREFIX to segregate the domain's data. If so, the
question becomes how to achieve it.
Here's the proposal: -- add a configfile option to the mailman utilities.
That's it! . . . . . . . . . . . . .
Advantages include: propose adding a "configure( filename)" function to incorporate the
- heavy lifting is limited to mm_cfg.py (or Defaults.py). I
configfile
- VAR_PREFIX could be defined on a per-domain basis;
mm_cfg.configure() would have to be prepared for this. - multiple instances of mailman utilities no longer required.
- transparent to existing configurations.
- ability to manage any of the mm_cfg parameters on a per-domain
basis.
Disadvantages include: than, managing a separate mailman installation for each domain.
- changes woulld be pervasive, and this cannot be underestimated.
However, most changes are either an additional getopt elif clause or
insuring that the configfile specification is propagated
appropriately. For the most part, these changes are straightforward. - all utility invocations for a given domain must use the same
configfile. This is no improvement over, but not more difficult
Other comments:
- an Exim ''mailman_vdom_transport'' can provide domain specific
config file to the mail wrapper. - httpd rewrite rules could generate domain (vhost) sepcific -- config=<confile> args to listinfo etc.
- I'm not sure about mailer requirements for Postfix, qmail, etc.
- a qrunner for each domain will be required; as is the case for
multiple installation copies.
Expected usage of the --config option for virtual domain processing
would be:
(this example is targeted for a Debian system running Exim4/Apache2
where all domain specific data for virtual domain "domain1.tld" is
kept in /var/vdomains/domain1.tld.))
Each virtual domain supplies a configfile. This config file might be
a 1 liner like:
VAR_PREFIX = /var/vdomains/domain1.tld/mailman/data
or it might contain other specializations as well.
The various system utiltiies would dereference the configfile for the
domain before invoking mailman utilities. For example (may contain
typos):
/etc/crontab might include lines like:
0 9 * * * list [ -x /usr/lib/mailman/cron/disabled ] && /usr/
lib/mailman/cron/disabled --config=/var/domains/domain1.tld/mailman.conf
An exim transport might contain a line like:
command = MAILMAN_WRAP --config=/var/vdomains/$domain/
mailman.conf
'${if def:local_part_suffix
{${sg{$local_part_suffix}{-(\\w+)(\\+.*)?}{\$1}}}
{post}}'
$local_part
An apache2 virtual host would contain directives like
<Location /cgi-bin/>
RewriteEngine on
RewriteRule ^listinfo$ listinfo?--config=/var/vdomains/
domain1.tld/mailman.conf </Location> or ScriptAliasMatch ^/mailing_lists/(.*) /usr/lib/mailman/cgi- bin/$1?--config=/var/vdomains/domain1.tld/mailman.conf
where the <configfile> contains my_cfg.py segments.
Comments? Advice? Reactions of Horror? Am I WAAAY off base?
Has this approach been previously considered and rejected?
FWIW, I've worked out a _basic_ implementation for mm_cfg.configure
(filename) and it's use by the cron utilities and would like to get
some reaction before going any further.
--rich
Rich Johnson <rjohnson@dogstar-interactive.com> writes:
AKA, "The Perennial Issue" (TPI)
Hehe. Right, we have run into this here again and again as well. :)
I've been looking at this for a while; I've scanned the archives; and
I've perused the code (well a chunk of it anyway). I realize that mailman _sort of_ supports virtual domains, but
doesn't _really_ support virtual domains.As I look at the situation from the perspective of a sysadmin or ISP,
there are two aspects that really bother me:
- comingling of data from separate virtual domains
There are two aspects to that:
On a filesystem level, the data from different virtual domains will always be thrown in some places under the same system user id, so this is something which cannot be solved without becoming root and doing some setuid magic.
Mailman's internal namespace for mailing lists does not include the virtual domain, so there are name clashes between the lists "foo", "foo@domain1.com" and "foo@domain2.com".
I am currently working on the "internal namespace" problem for a certain installation, and I'm not overly concerned with the "same system user" issue.
As far as I can tell, the "internal namespace" problem itself is not very difficult to solve. However, some of its consequences may be, and I'll solve those problems as they come.
I had not really planned to go public with that branch of mine yet, but I think it makes sense in with respect to this discussion:
http://nix.lauft.net/mailman/README.VHOST Project description
http://nix.lauft.net/mailman/ GNU-style patches
http://git.n-dimensional.de/mailman-virtualhost.git/ git repository, forked off the Mailman 2.1.7 release.
bawue.net is currently using Mailman 2.1.7, and we require a solution which allows three different lists named "foo", "foo@bar.com" and "foo@bla.org" on the same mailman installation. Thus we have started adapting Mailman accordingly mid-2006-02, naming it our "vhost branch".
The general idea is to have use the "foo", "foo@bar.com" and "foo@bla.org" strings as the internal list identifiers, and then successively solve or work around all the issues this change implies.
For more details, read http://nix.lauft.net/mailman/README.VHOST (the code itself is not of practical use yet).
Our goal is to give this branch to the Mailman project if they want it. If they do not for any reason, we'll have to maintain our vhost branch until Mailman 3 with all the necessary features has been released. :)
- ''site'' password shared between virtual domains
According to some "Mailman 3" documents I've stumbled upon, that issue is going to be addressed in Mailman 3's user database. However, I have not seen anything looking like a timeframe :)
This is obviously a problem which will need to be addressed in some way. I have not gotten that far yet, though, so I have not yet worked out any solution options.
From my perusals I think what I'm really asking for is a per-domain
assignment of VAR_PREFIX to segregate the domain's data. If so, the
question becomes how to achieve it.
That sounds suspiciously similar to "one mailman installation per domain" :)
Here's the proposal: -- add a configfile option to the mailman utilities.
Indeed. Then you have one software installation (binaries, programs, libraries) and all the rest is duplicated per virtual domain. OK, that may fix your problem, but not mine :)
Gruß,
Hans Ulrich Niedermann
At 2:23 PM +0100 2006-03-03, Hans Ulrich Niedermann wrote:
Our goal is to give this branch to the Mailman project if they want it. If they do not for any reason, we'll have to maintain our vhost branch until Mailman 3 with all the necessary features has been released. :)
If you upload the code to the SourceForge "patches" page for
Mailman, the core developers will be much more likely to look at what you've got and to consider it for inclusion in a future version.
The key people you've got to convince are Tokio and Mark -- Barry
is primarily working on his real job, and doing what he can for Mailman3 in his non-existent "spare time", although he does try to at least keep abreast of what is going on with Mailman 2.x.
-- Brad Knowles, <brad@stop.mail-abuse.org>
"Those who would give up essential Liberty, to purchase a little temporary Safety, deserve neither Liberty nor Safety."
-- Benjamin Franklin (1706-1790), reply of the Pennsylvania
Assembly to the Governor, November 11, 1755
LOPSA member since December 2005. See <http://www.lopsa.org/>.
Brad Knowles <brad@stop.mail-abuse.org> writes:
At 2:23 PM +0100 2006-03-03, Hans Ulrich Niedermann wrote:
Our goal is to give this branch to the Mailman project if they want it. If they do not for any reason, we'll have to maintain our vhost branch until Mailman 3 with all the necessary features has been released. :)
If you upload the code to the SourceForge "patches" page for Mailman, the core developers will be much more likely to look at what you've got and to consider it for inclusion in a future version.
I'll do that as soon as I have something a) working b) clean (code) c) pretty (concept) d) as small a change as absolutely necessary
The key people you've got to convince are Tokio and Mark -- Barry is primarily working on his real job, and doing what he can for Mailman3 in his non-existent "spare time", although he does try to at least keep abreast of what is going on with Mailman 2.x.
I'll keep that in mind, thank you.
Gruß,
Hans Ulrich Niedermann
Hans Ulrich Niedermann wrote:
Brad Knowles <brad@stop.mail-abuse.org> writes:
The key people you've got to convince are Tokio and Mark --
Since I've been nominated as a key person to convince, here's one remark.
The general idea is to have use the "foo", "foo@bar.com" and "foo@bla.org" strings as the internal list identifiers, and then successively solve or work around all the issues this change implies.
There are existing patches that are linked directly or indirectly from FAQ 4.47. These all seem to use things like foo_bar.com and foo_bla.org as the internal list identifier and they all seem to do an incomplete job of "solve or work around all the issues this change implies".
Anyway, my intent is not to critique other solutions, but to say that I would much prefer to see a directory inserted rather than a host_name appended. This has performance advantages and might fit better with a scheme of "hashed" intermediate directories to help sites with very large numbers of lists. Once you add the infrastructure for one intermediate directory, it may become simpler to add more intermediate directories
I.e, for the initial cut, split the lists/<listname> structure into lists/<hostname>/<listname> and similarly for archives/private and archives/public.
Anyway, it's your project, but I think we'd all welcome a complete solution to this problem.
-- Mark Sapiro <msapiro@value.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
Mark Sapiro <msapiro@value.net> writes:
Anyway, my intent is not to critique other solutions, but to say that I would much prefer to see a directory inserted rather than a host_name appended. This has performance advantages and might fit better with a scheme of "hashed" intermediate directories to help sites with very large numbers of lists. Once you add the infrastructure for one intermediate directory, it may become simpler to add more intermediate directories.
I.e, for the initial cut, split the lists/<listname> structure into lists/<hostname>/<listname> and similarly for archives/private and archives/public.
Actually, implementing the lists/<hostname>/<localpart> and archives/(private|public)/<hostname>/<localpart> was one of the first things I have implemented, as it is one of the easiest parts and had been mentioned at http://www.zope.org/Members/bwarsaw/MailmanDesignNotes/VirtualHosting
It's not as clean as I'd like it to be yet, though: There is the very same code to create those directories in both Mailman/Site.py and Mailman/Archives/Archives.py (two nested try: blocks with the os.umask() where the inner try finally calls os.makedirs()).
OTOH, one can argue that Site.py and Archives.py handle fundamentally different things and just happen to need the same code. Still, I always become wary when I see the same code in different places :)
Anyway, it's your project, but I think we'd all welcome a complete solution to this problem.
Good. Let's see how far I can get.
Gruß,
Hans Ulrich Niedermann
--On 4 March 2006 06:16:12 +0100 Hans Ulrich Niedermann <hun@n-dimensional.de> wrote:
Actually, implementing the lists/<hostname>/<localpart> and archives/(private|public)/<hostname>/<localpart> was one of the first things I have implemented, as it is one of the easiest parts and had been mentioned at http://www.zope.org/Members/bwarsaw/MailmanDesignNotes/VirtualHosting
I'd propose a slight variation on that, to better accommodate campus/corporate setups, as well as hosting providers:
lists/tld/subdomain/.../listname
for example, I'd have:
lists/uk/ac/sussex/ lists/uk/ac/sussex/physics lists/uk/ac/sussex/chemistry lists/uk/ac/sussex/english ... and we host some 'external' domains, too: lists/com/example
-- Ian Eiloart IT Services, University of Sussex
On Mar 9, 2006, at 9:55 AM, Ian Eiloart wrote:
Actually, implementing the lists/<hostname>/<localpart> and archives/(private|public)/<hostname>/<localpart> was one of the first things I have implemented, as it is one of the easiest parts and had been mentioned at http://www.zope.org/Members/bwarsaw/MailmanDesignNotes/VirtualHosting
I'd propose a slight variation on that, to better accommodate campus/corporate setups, as well as hosting providers:
lists/tld/subdomain/.../listname
[...snip...]
With all these variations, it might be reasonable to consider dumping
the path macros altogether and switch to a functional model.
The path mapping functions could be supplied by mm_cfg and modified
as appropriate for the installation.
For example, the existing 2.1 storage is functionally equivalent to: def list_dir ( domain, list_localpart ) { return os.path.join( VAR_PREFIX, 'lists', list_localpart )
Whereas what you're asking for is: def list_dir( domain, list_localpart ){ leaf = list_localpart for dom_part in domain.split('.'): leaf = os.path.join( dom_part, leaf ) return os.path.join( VAR_PREFIX, 'lists', leaf )
And what works for _my systems_ would be: def list_dir( domain, list_localpart ){ return os.path.join( '/var/vdomains/', domain, '/mailman/ lists', list_localpart)
IF one simply _MUST_ have different mapping regimes for different
domains....well, then encode it into your mm_cfg.list_dir().
On Mar 9, 2006, at 1:02 PM, Rich Johnson wrote:
On Mar 9, 2006, at 9:55 AM, Ian Eiloart wrote:
Actually, implementing the lists/<hostname>/<localpart> and archives/(private|public)/<hostname>/<localpart> was one of the
first things I have implemented, as it is one of the easiest parts and had been mentioned at http://www.zope.org/Members/bwarsaw/MailmanDesignNotes/ VirtualHostingI'd propose a slight variation on that, to better accommodate campus/corporate setups, as well as hosting providers:
lists/tld/subdomain/.../listname
[...snip...]
With all these variations, it might be reasonable to consider dumping the path macros altogether and switch to a functional model. The path mapping functions could be supplied by mm_cfg and modified as appropriate for the installation.
Oh wait!
Mailman/Site.py already provides this function--but the rest of the
system never propagates the domain--neither do the support utilities
(like check_perms)
Rich Johnson <rjohnson@dogstar-interactive.com> writes:
On Mar 9, 2006, at 1:02 PM, Rich Johnson wrote:
[ lists/<hostname>/<localpart> vs. lists/tld/subdomain/.../listname vs. ... ]
With all these variations, it might be reasonable to consider dumping the path macros altogether and switch to a functional model. The path mapping functions could be supplied by mm_cfg and modified as appropriate for the installation.
Oh wait!
Mailman/Site.py already provides this function--but the rest of the
system never propagates the domain--neither do the support utilities
(like check_perms)
There are multiple places in the code where pathnames and URLs are built outside of Mailman/Site.py. In the vhost branch, I need to change all the code parts generating a path anyway, so I'm moving the actual generation into a function in Mailman/Site.py while I'm at it.
Then if someone needs special file system layout later, he can rewrite Mailman/Site.py into "from MySite import *" and implement his own functions mapping objects to files and vice versa in a MySite.py module. However, I'm not overly concerned with the details of all possible layouts - that stuff is easy to change once it is concentrated in a single module.
Gruß,
Hans Ulrich Niedermann
On Thu, Mar 09, 2006 at 02:55:14PM +0000, Ian Eiloart wrote:
I'd propose a slight variation on that, to better accommodate campus/corporate setups, as well as hosting providers:
lists/tld/subdomain/.../listname
for example, I'd have:
lists/uk/ac/sussex/ lists/uk/ac/sussex/physics lists/uk/ac/sussex/chemistry lists/uk/ac/sussex/english
I second that.
Regards, Msquared...
I don't follow why one would need that, if you already separated based on email domain. In other words, if you had list@sussex.com, list@physics.sussex.com, and list@english.sussex.com, why not:
/lists/sussex.com/list /lists/physics.sussex.com/list /lists/english.sussex.com/list
?
Bob
---------- Original Message ----------- From: Msquared <sub1.dev.mailman@msquared.id.au> To: mailman-developers@python.org Sent: Fri, 10 Mar 2006 08:37:53 +0800 Subject: Re: [Mailman-Developers] Virtual Domains Redux (w proposal)
On Thu, Mar 09, 2006 at 02:55:14PM +0000, Ian Eiloart wrote:
I'd propose a slight variation on that, to better accommodate campus/corporate setups, as well as hosting providers:
lists/tld/subdomain/.../listname
for example, I'd have:
lists/uk/ac/sussex/ lists/uk/ac/sussex/physics lists/uk/ac/sussex/chemistry lists/uk/ac/sussex/english
I second that.
Regards, Msquared...
Mailman-Developers mailing list Mailman-Developers@python.org http://mail.python.org/mailman/listinfo/mailman-developers Mailman FAQ: http://www.python.org/cgi-bin/faqw-mm.py Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-developers/bob%40nleaudio.com
Security Policy: http://www.python.org/cgi-bin/faqw-mm.py?req=show&file=faq01.027.htp ------- End of Original Message -------
On Thu, Mar 09, 2006 at 08:16:39PM -0500, Bob Puff wrote:
I don't follow why one would need that, if you already separated based on email domain. In other words, if you had list@sussex.com, list@physics.sussex.com, and list@english.sussex.com, why not:
/lists/sussex.com/list /lists/physics.sussex.com/list /lists/english.sussex.com/list
Scope of ownership and management.
These might have different owners:
/lists/mine.example.net/ /lists/yours.example.net/
but these might have the same owner:
/lists/dept1.foo.org/ /lists/dept2.foo.org/
If it were possible to control access/ownership/etc according to subdirectories, this would allow you to grant control of subdirectories from the appropriate level down:
/lists/org/foo/ is for *.foo.org /lists/net/example/mine/ is for me /lists/net/exmaple/yours/ is for you
Of course I don't know if mailman yet allows such delegation of control, but it would be nifty...
You could still control access like that through unix/linux directory ownerships, for example, though.
Regards, Msquared...
---------- Original Message ----------- From: Msquared <sub1.dev.mailman@msquared.id.au> To: mailman-developers@python.org Sent: Fri, 10 Mar 2006 10:00:07 +0800 Subject: Re: [Mailman-Developers] Virtual Domains Redux (w proposal)
On Thu, Mar 09, 2006 at 08:16:39PM -0500, Bob Puff wrote:
I don't follow why one would need that, if you already separated based on email domain. In other words, if you had list@sussex.com, list@physics.sussex.com, and list@english.sussex.com, why not:
/lists/sussex.com/list /lists/physics.sussex.com/list /lists/english.sussex.com/list
Scope of ownership and management.
These might have different owners:
/lists/mine.example.net/ /lists/yours.example.net/
but these might have the same owner:
/lists/dept1.foo.org/ /lists/dept2.foo.org/
If it were possible to control access/ownership/etc according to subdirectories, this would allow you to grant control of subdirectories from the appropriate level down:
/lists/org/foo/ is for *.foo.org /lists/net/example/mine/ is for me /lists/net/exmaple/yours/ is for you
Of course I don't know if mailman yet allows such delegation of control, but it would be nifty...
You could still control access like that through unix/linux directory ownerships, for example, though.
I think we're drifting here from a logical format. If there is to be shared ownership, I think that needs to be done with a different database. It could be a nightmare from the admin side if you group things by who wants to own what lists, rather than by domain. I believe the initial point behind the start of this is that list@foo and list@bar should be able to cohabitate on the same install.
Bob
On Thu, Mar 09, 2006 at 09:04:59PM -0500, Bob Puff wrote:
I think we're drifting here from a logical format.
You could be right. My structural and pedantic parts liked the subdirectories for parts of hostnames, but I'm not glued to the idea yet. :o)
I believe the initial point behind the start of this is that list@foo and list@bar should be able to cohabitate on the same install.
You are right, and /lists/foo.example.net/list is a perfectly good way to differentiate.
Regards, Msquared...
At 9:04 PM -0500 2006-03-09, Bob Puff wrote:
I think we're drifting here from a logical format. If there is to be shared ownership, I think that needs to be done with a different database. It could be a nightmare from the admin side if you group things by who wants to own what lists, rather than by domain.
Actually, his proposed scheme does make sense for a larger-scale
environment. Indeed, that's the second-most scalable way I know of to do it. The most scalable would have some sort of side index system and use good hashing algorithms to avoid having a billion subdirectories under /usr/local/mailman/lists/com/ and maybe just a few hundred under /usr/local/mailman/lists/info/.
For smaller environments, you might want a different option.
I think what we really need is some way to guarantee that any of
several different suitable formats could be used, some of which might be more easily understood at a glance, others which might be more complex but also more scalable.
-- Brad Knowles, <brad@stop.mail-abuse.org>
"Those who would give up essential Liberty, to purchase a little temporary Safety, deserve neither Liberty nor Safety."
-- Benjamin Franklin (1706-1790), reply of the Pennsylvania
Assembly to the Governor, November 11, 1755
LOPSA member since December 2005. See <http://www.lopsa.org/>.
On Mar 9, 2006, at 9:33 PM, Brad Knowles wrote:
[...snip...] I think what we really need is some way to guarantee that any of several different suitable formats could be used, some of which might be more easily understood at a glance, others which might be more complex but also more scalable.
Put 3 or 4 variants in Mailman/Site.py and activate one during
installation?
We're getting dangerously close to some OO programming issues!
[...snip...]
I think we're drifting here from a logical format. If there is to
be shared ownership, I think that needs to be done with a different
database. It could be a nightmare from the admin side if you group things by who wants
to own what lists, rather than by domain. I believe the initial point
behind the start of this is that list@foo and list@bar should be able to
cohabitate on the same install.
Not quite. It depends on your interpretation of what 'cohabitate'
means.
As the initiator, I'll chime in with the following:
_processed_ by the same install? yes.
_cohabitate_? perhaps. But this is a site and/or domain
administrator configuration decision--and not imposed by the
developer. I've been pretty consistent about my aversion to
comingling data from separate domains in the same tree. I view the
domain split as _more_ important that the virtual service provided--
be it apache vhosts, exim vusers, or mailman. Ideally it could be a
mount point.
base-domain->site scoping [N.B. I'm still thinking about my
- Ephemeral data such as queues and logs might or might not cohabit.
- Persistent data such as list configuration, subscriber lists, and
archives must be severable - HTTP and mail message templates probably require list->sub-domain-
IMO: position on this issue]
A good part of this discussion seems to revolve around whether
mailman ''plays well with others''. Where the ''others'' are
amorphously defined.
Rich Johnson <rjohnson@dogstar-interactive.com> writes:
As the initiator, I'll chime in with the following:
[ list@foo and list@bar on the same MM instance ]
_processed_ by the same install? yes.
_cohabitate_? perhaps. But this is a site and/or domain
administrator configuration decision--and not imposed by the
developer. I've been pretty consistent about my aversion to
comingling data from separate domains in the same tree. I view the
domain split as _more_ important that the virtual service provided-- be it apache vhosts, exim vusers, or mailman. Ideally it could be a
mount point.IMO:
- Ephemeral data such as queues and logs might or might not cohabit.
...depending on the number of mails per day, the number of lists, number of subdomains, number of subdomain admins, and how the admin tasks are distributed between the site admins and the subdomain admins.
- Persistent data such as list configuration, subscriber lists, and
archives must be severable
This can be achieved by consequent usage of Mailman/Site.py - basically concentrating all calls to os.path.join() in Mailman/Site.py.
- HTTP and mail message templates probably require list->sub-domain-
base-domain->site scoping [N.B. I'm still thinking about my
position on this issue]
Let me cite the comment from MM's 2.1.7 Mailman/Utils.py findtext() function:
# When looking for a template in a specific language, there are 4 places
# that are searched, in this order:
#
# 1. the list-specific language directory
# lists/<listname>/<language>
#
# 2. the domain-specific language directory
# templates/<list.host_name>/<language>
#
# 3. the site-wide language directory
# templates/site/<language>
#
# 4. the global default language directory
# templates/<language>
Looks like your idea is already in place. :)
Gruß,
Hans Ulrich Niedermann
On Mar 10, 2006, at 2:11 PM, Hans Ulrich Niedermann wrote:
Rich Johnson <rjohnson@dogstar-interactive.com> writes:
[...snip...] base-domain->site scoping [N.B. I'm still thinking about my
- HTTP and mail message templates probably require list->sub-domain-
position on this issue]
Let me cite the comment from MM's 2.1.7 Mailman/Utils.py findtext() function:
# When looking for a template in a specific language, there are4 places # that are searched, in this order: # # 1. the list-specific language directory # lists/<listname>/<language> # # 2. the domain-specific language directory # templates/<list.host_name>/<language> # # 3. the site-wide language directory # templates/site/<language> # # 4. the global default language directory # templates/<language>
Looks like your idea is already in place. :)
Hooray! The scoping exists!. (FWIW, I needed some good news today!)
Now, if I can use Site.py (or one of its siblings) to bring it all
into a domain-rooted fs by mapping:
perhaps via: Site.list_template_dir(). Site.domain_template_dir(),
- lists/<listname>/<language> -> /var/vdomains/<list.host_name>/ var/lib/mailman/lists/<llist.local_name>/<language>
- templates/<list.host_name> -> /var/vdomains/<list.host_name>/ var/lib/mailman/templates/<language>
and so on....
......I'll declare victory and wait for the next release (...well,
maybe :-)
I hope that's not too much to ask.
On Sat, 2006-03-04 at 14:57 -0500, Bob Puff wrote:
I.e, for the initial cut, split the lists/<listname> structure into lists/<hostname>/<listname> and similarly for archives/private and archives/public.
Definite +1 on that!
Yep, that's definitely where my thinking was leading the last time I worked on this. FWIW, in Mailman 3 I've been thinking that the "list id" will essentially be the full posting address, so that it's pretty clear what "foo@dom1.org" and "foo@dom2.org" point to.
Let me make two other suggestion for those of you working on patches. First, generate your patches against the Mailman trunk, for what will eventually be Mailman 2.2. There's no way we can add this stuff to MM2.1, but Tokio did the heavy lifting a while back to whip the trunk into shape, and all patches are being applied to both the trunk and the 2.1-maint branch. At some point, they'll start to diverge but for now they should be pretty similar (modulo some i18n stuff).
Also, now that SF provides Subversion support, I very strongly want to migrate to it. Among many other advantages, this will make it easier to create experimental branches to work on things like this.
-Barry
Barry Warsaw <barry@python.org> writes:
On Sat, 2006-03-04 at 14:57 -0500, Bob Puff wrote:
I.e, for the initial cut, split the lists/<listname> structure into lists/<hostname>/<listname> and similarly for archives/private and archives/public.
Definite +1 on that!
Yep, that's definitely where my thinking was leading the last time I worked on this. FWIW, in Mailman 3 I've been thinking that the "list id" will essentially be the full posting address, so that it's pretty clear what "foo@dom1.org" and "foo@dom2.org" point to.
Yupp, I like that, too. My "vhost branch" supports both types of list id (MailList.internal_name()):
- traditional site wide (and postfix style virtual) lists (named "foo")
- new "vhost lists" named ("foo@dom1.org" and "foo@dom2.org") That should make vhost->MM3 migration easier :)
Let me make two other suggestion for those of you working on patches. First, generate your patches against the Mailman trunk, for what will eventually be Mailman 2.2.
That is CVS HEAD in the "mailman" CVS module, I presume. Now that I have finally gotten through to the anoncvs server, I have fetched mailman HEAD and 2.1-maint.
There's no way we can add this stuff to MM2.1, but Tokio did the heavy lifting a while back to whip the trunk into shape, and all patches are being applied to both the trunk and the 2.1-maint branch. At some point, they'll start to diverge but for now they should be pretty similar (modulo some i18n stuff).
Ah good. If the difference is that small, I'll continue with 2.1 first (as I have started from there) and port to HEAD (2.2) when I have the basics working on 2.1.
Also, now that SF provides Subversion support, I very strongly want to migrate to it. Among many other advantages, this will make it easier to create experimental branches to work on things like this.
Definite +1 on ditching CVS. And (at least theoretically by using svk), SVN is even supposed to be usable by the non-priviledge masses who have not been blessed with write access to the central repository. *That* is the killer advantage IMHO.
Gruß,
Hans Ulrich Niedermann
Barry Warsaw <barry@python.org> writes:
Also, now that SF provides Subversion support, I very strongly want to migrate to it. Among many other advantages, this will make it easier to create experimental branches to work on things like this.
Is there a time schedule for migration SVN, and would I get to play with a branch there? :) I think my vhost branch is ready to be turned into an experimental SVN branch.
I would first start on MM 2.2 and introduce the necessary abstractions for file locations and the like, without changing the actual behaviour. Once those abstrations are in place, I would then build the vhost branch on that and thus make the vhost patch much smaller and easier to comprehend.
Even if you do not want my vhost changes in official Mailman, those abstractions could still be beneficial for both official Mailman and for independent maintenance of a vhost branch.
The following is a more detailed list which shows the current state of the vhost branch. It is not complete yet (there will still be a number of issues to solve, and I will do so), but the basics are there:
Support for three list types:
- site wide lists without "postfix style virtual hosting":
- internal_name()=="foo", like in 2.1.7)
- uses the DEFAULT_EMAIL_HOST and DEFAULT_URL_HOST
- site wide lists with "postfix style virtual hosting":
- internal_name()=="fox", like in 2.1.7
- "fox" here conflicts with site wide "fox" even in case of different host_name
- uses special email_host and (possibly) url_host
- vhost lists
- internal_name()=="foo@bar" (new in vhost branch)
- no conflicts with site-wide "foo" or vhost list "foo@bleh"
- requires registration of the url_host<->email_host relation in mm_cfg (cf. VIRTUAL_HOSTS, add_virtualhost()) by the site admin Note: Type 2 lists may be migrated to type 3 lists, so I have not tested that type 2 lists work all that well. If we drop type 2 lists altogether, that work would have been in vain, so I'm not very much concerned about them. The architecture itself does not prevent their continued use.
- site wide lists without "postfix style virtual hosting":
Web and E-Mail templates produce the expected results.
The Web interface works as expected, as far as one can tell without executing an automated test with complete coverage:
- (un)subscribing to lists works
- administrating the list settings works
- moderating postings works The URL space looks like this (for the example lists from above): http://lists.site-wide/listinfo/foo http://lists.site-wide/listinfo/fox http://lists.bar/listinfo/foo http://lists.bleh/listinfo/bleh Possible issues I don't care about on my installation:
- There is no single web site which lists all lists.
- All lists using the same url_host must use the same email_host.
- You can/must use a single Apache <VirtualHost> for all lists.* URLs. (They do necessarily have to be called "lists.*").
- You cannot have different basic URLs for different url_hosts, i.e. integration into existing websites is difficult/impossible.
Command line list creation works.
Sending mail to site wide lists and vhost lists works.
Generate proper aliases and virtual aliases for Postfix.
A few things are still to do:
Introduce the role of a vhost-domain admin between the site admin and the list admins. This requires per vhost-domain storage modifiable by the vhost-domain admin which we do not have. (The vhost-domain admin should be able to modify his password, right?)
Enforce the requirement of one mailman@vhost-domain list per vhost-domain.
Should we migrate the site wide lists with "postfix style virtual hosting" to vhost lists? I have not done this yet in order to avoid additional work in the proof-of-concept phase.
Backing out unnecessary stuff introduced while getting to know the code and generally clean up stuff.
CGI list creation/removal do not work yet.
...
If you want to examine the vhost branch yourself, here are a number of links:
Current patch against mailman-2.1.7 with the 20060114 patch: http://nix.lauft.net/mailman/mailman-2.1.7-20060114-to-vhost-current.patch The README.VHOST containing more text on issues and solutions: http://nix.lauft.net/mailman/README.VHOST The overview page: http://nix.lauft.net/mailman/ Cogito/Git repository: http://git.n-dimensional.de/mailman-virtualhost.git/
Gruß,
Hans Ulrich Niedermann
On Fri, Mar 03, 2006 at 01:39:18PM -0800, Mark Sapiro wrote:
I.e, for the initial cut, split the lists/<listname> structure into lists/<hostname>/<listname> and similarly for archives/private and archives/public.
Just a thought on this: might it be better to mangle the directories like so:
<hostname>/lists/<listname> <hostname>/archives/<listmame> etc
so as to group things on a per-host basis? One reason for doing so is that it (to me) makes more sense especially if you are hosting many domains that are not related or are different clients, etc. It simplifies the view of things from a per-host perspective.
Perhaps even this:
<hostname>/<listname>/list <hostname>/<listname>/archive etc
Even better, perhaps make it configurable. :o)
Regards, Msquared...
On Mar 6, 2006, at 12:44 AM, Msquared wrote:
On Fri, Mar 03, 2006 at 01:39:18PM -0800, Mark Sapiro wrote:
I.e, for the initial cut, split the lists/<listname> structure into lists/<hostname>/<listname> and similarly for archives/private and archives/public.
Just a thought on this: might it be better to mangle the directories like so:
<hostname>/lists/<listname> <hostname>/archives/<listmame> etc
so as to group things on a per-host basis? One reason for doing so is that it (to me) makes more sense especially if you are hosting many domains that are not related or are different clients, etc. It
simplifies the view of things from a per-host perspective.Perhaps even this:
<hostname>/<listname>/list <hostname>/<listname>/archive etc
Even better, perhaps make it configurable. :o)
Regards, Msquared...
Mailman-Developers mailing list Mailman-Developers@python.org http://mail.python.org/mailman/listinfo/mailman-developers Mailman FAQ: http://www.python.org/cgi-bin/faqw-mm.py Searchable Archives: http://www.mail-archive.com/mailman-users% 40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman- developers/rjohnson%40dogstar-interactive.com
Security Policy: http://www.python.org/cgi-bin/faqw-mm.py? req=show&file=faq01.027.htp
I'll second this!
In general I object to co-mingling domain specific data. it was the
main motivation for my initial post. I'm glad it triggered a bit
more discussion that I expected. :-)
I'd encourage all to consider also: lists in a single domain.
- domains are likely to have different requirements and/or be
separately administered. - The storage format is not necessarily a file-system. (as other
discussions have indicated) - There's even an argument that storage format may vary between
In any case we have: archives <= f(domain,list,fmt) list <= f(domain,list, fmt)
How about a macro capability with $hosthame and $listname (ala Exim's
$local_part, $domain) for filesystem storage?
One could specify:
LIST_DATA_DIR = /var/lib/mailman/%hostname/lists
or
LIST_DATA_DIR = /var/vdomains/%hostname/mailman/lists
in the config file according to your system/site conventions.
Another, more configurable, mechanism would be implementing
''repository'' objects (initially implemented for filesystem
storage): These ''repositories'' would be indexed by ''hostname''.
Their specification could be modeled after Apache's <VirtualHost>.
To wit (assuming a way to interpret this snippit):
<VirtualHost low-volume.tld>
ArchivesRepository filesystem
ListsRepository filesystem
FilesystemRoot /var/vdomains/low_volume/mailman
</VirtualHost>
<VirtualHost high-volume.tld> ArchivesRepository filesystem ListsRepository database DatabaseType Postgres FilesystemRoot /var/vdomains/high_volume/mailman DB_info mailman_db/mailman_usr/mailman_dbpwd </VirtualHost>
Or even (tying these two together):
FilesystemRoot /var/vdomains/%hostname/mailman DatabaseType postgres DB_info mailman-db/db-user/db-pwd <VirtualHost low-volume.tld> ArchivesRepository filesystem ListsRepository filesystem </VirtualHost> <VirtualHost high-volume.tld> ArchivesRepository filesystem ListsRepository database </VirtualHost>
--rich
--On 3 March 2006 13:39:18 -0800 Mark Sapiro <msapiro@value.net> wrote:
Anyway, my intent is not to critique other solutions, but to say that I would much prefer to see a directory inserted rather than a host_name appended.
I guess that's a legacy term. Shouldn't we be using the term "domain_name" to refer to mail domains? I don't have lots of hosts, and lots of mail domains, but none of my host names match any of my domain names.
-- Ian Eiloart IT Services, University of Sussex
participants (8)
-
Barry Warsaw -
Bob Puff -
Brad Knowles -
Hans Ulrich Niedermann -
Ian Eiloart -
Mark Sapiro -
Msquared -
Rich Johnson