Re: [Mailman-Users] Virtual domain not quite working on HTTP (but fine on SMTP)

2009-06-19 Thread Rick Moen
Quoting Mark Sapiro (m...@msapiro.net):

> Yes it is. 'listinfo' is a CGI. You need a
> ScriptAlias /mailman/ "/usr/local/mailman/cgi-bin/"

The Apache conf has:
ScriptAlias /mailman/ /usr/lib/cgi-bin/mailman/

I didn't harp on that in either of my posts because I _had_ pointed out 
that the Mailman Web pages _do work_ for the default host -- and also
invited people to have a look at http://linuxmafia.com/mailman/listinfo
and subpages thereof, if they had any doubts.

-=but=-, the above ScriptAlias was neatly tucked into the stanza for the
default host.  And:

> (or whatever the correct path is) in your httpd.conf where it will
> apply to the lists.linuxgazette.net host. I.e. it needs to be in the
> VirtualHost block for each host with lists or it needs to be outside
> of the virtual hosts section so it applies globally.

That was it!  Fixed, now.

Damn.  Bear in mind, I've just had a forced transition from Apache 1.3.x
to Apache2 (on account of sudden destruction of the old box), so my
excuse is that Debian's Apache2 conffile setup is rather different from 
what I was used to.

Thank you, Mark.  And thank you, good gentleman all.


-- 
Cheers,  Notice:  The value of your Hofstadter's Constant 
Rick Moen(the average amount of time you spend each month 
r...@linuxmafia.com  thinking about Hofstadter's Constant) has just 
McQ!  (4x80) been adjusted upwards.
--
Mailman-Users mailing list
Mailman-Users@python.org
http://mail.python.org/mailman/listinfo/mailman-users
Mailman FAQ: http://wiki.list.org/x/AgA3
Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/
Unsubscribe: 
http://mail.python.org/mailman/options/mailman-users/archive%40jab.org

Security Policy: http://wiki.list.org/x/QIA9


Re: [Mailman-Users] Virtual domain not quite working on HTTP (but fine on SMTP)

2009-06-19 Thread Rick Moen
Quoting Adam McGreggor (adam-mail...@amyl.org.uk):

> >   # cat /var/www/gazette/.htaccess 
> >   redirect 301 /index.html
> >   http://lists.linuxgazette.net/mailman/listinfo/
> 
> that 404's for me: have you got the Mailman Apache stanzas set-up in
> lists.linuxgazette.net's vhost config? I've not had issues using
> ServerAlias directives, fwiw.

Um, that's not 404, you're being 301-redirected by the .htaccess file
to a URL that _is_ 404 on account of Mailman not providing the virthost
there.  Here, let's temporarily disable the .htaccess file, and see:

# cd /var/www/gazette/
linuxmafia:/var/www/gazette# mv .htaccess .htaccess-save
linuxmafia:/var/www/gazette# touch HELLO-WORLD

You'll please note that http://lists.linuxgazette.net/ (and
http://lists.linuxgazette.net/HELLO-WORLD ) are not, in fact, 404.

But anyway, since you ask, here's the relevant excerpt from the Apache
config:


DocumentRoot /var/www/gazette



Options Indexes MultiViews FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all




> I would not touch that. Even with the travesty that is Pkg-exim4, I
> still use something along the lines (pretty much) of that per
> 

You know, that is very likely what I did in the prior incarnation of my
machine, and I'd certainly consider doing it again -- but being very
careful, because this is a production system.  I'm glad to go with
anything that works:  Trying first what the package maintainers and Debian
people recommend seemed worthwhile.  In any event, the current setup is 
just one small problem (http on the virthost) away from 100% success, so
maybe it can be debugged.

Also, since Exim-Mailman integration is working fine, and it's Mailman's
virthost communication with Apache that's broken, I'm not sure switching
to the admittedly far more elegant approach of
http://exim.org/howto/mailman21.html would address my current problem.


> You may need a 'clear' clause before the line below: search the
> archives of this list for discussions/thoughts/advice thereto.
> 
> >   VIRTUAL_HOSTS = {'lists.linuxgazette.net':'lists.linuxgazette.net'}
> [...]

Thanks.  I'll try that.  

(After restarting qrunning:)  Nope.  That didn't do it.


> >   MTA = 'Postfix'
> 
> I'd change that, as you're using Exim.

I don't believe that's really right.  The keyword "Postfix" in that
context just means "use Postfix-style domain semantics", which are not
in any way Postfix-specific but are just a particular way of dealing
with aliases, if I understand correctly.

--
Mailman-Users mailing list
Mailman-Users@python.org
http://mail.python.org/mailman/listinfo/mailman-users
Mailman FAQ: http://wiki.list.org/x/AgA3
Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/
Unsubscribe: 
http://mail.python.org/mailman/options/mailman-users/archive%40jab.org

Security Policy: http://wiki.list.org/x/QIA9


Re: [Mailman-Users] Virtual domain not quite working on HTTP (but fine on SMTP)

2009-06-18 Thread Adam McGreggor
On Tue, Jun 16, 2009 at 11:37:30PM -0700, Rick Moen wrote:
> Greetings, good people.  Problem summary:  After server rebuild, 
> virtual hosts work for SMTP, but Mailman's Web pages are appearing
> for the main host only and _not_ the virtual host.

[...]

> After some fussing about concerning exim4/mailman integration, I
> stumbled on details about POSTFIX_STYLE_VIRTUAL_DOMAINS and its use even
> with non-Postfix MTAs.  (I put the required plumbing into
> /etc/exim4/conf.d/*.  It works.)  I did read the Debian folks'
> /usr/share/doc/mailman/README.Exim4.Debian , which includes in part:

I would not touch that. Even with the travesty that is Pkg-exim4, I
still use something along the lines (pretty much) of that per


>   Here's a way to integrate mailman with Exim4 that will automatically
>   play nice with mailman's virtual domains support and VERP. It does not
>   require dedicating domain(s) to mailman.

My kludges don't care about subdomains/"list only" domains.

> http://files.technomage.net/postfix_mailman.txt -- and, consequently, 
> completed Exim integration by running /var/lib/mailman/bin/genaliases, 
> and, lo!  /var/lib/mailman/data/{aliases|virtual-mailman} came into
> existence, and Exim stopped generating errors.  More important, the
> Exim/Mailman jointly [re-]started processing mail for the mailing lists
> within both domains.  Life was good.  Almost.

IMO, life's waaay too short to genaliases. the configs in
Nigel's doc makes that a thing of the past (it's probably worth
noting, I am a lazy sysadmin, and i automate as much as possible, and
just couldn't make sense of Postfix when i inherited a box with
postfix as its MTA: that got changed).

> There remains the matter of Mailman's Web pages:  Those for domain
> linuxmafia.com are present.  (See: http://linuxmafia.com/mailman/listinfo/)
> Those for domain lists.linuxgazette.net are not.  See:
> http://lists.linuxgazette.net/mailman/listinfo/ -- as you'll notice,
> Apache2 does recognise the domain.  The Apache document root for that
> location, /var/www/gazette, has an .htaccess file in it, as follows:
> 
>   # cat /var/www/gazette/.htaccess 
>   redirect 301 /index.html
>   http://lists.linuxgazette.net/mailman/listinfo/

that 404's for me: have you got the Mailman Apache stanzas set-up in
lists.linuxgazette.net's vhost config? I've not had issues using
ServerAlias directives, fwiw.

[...]

You may need a 'clear' clause before the line below: search the
archives of this list for discussions/thoughts/advice thereto.

>   VIRTUAL_HOSTS = {'lists.linuxgazette.net':'lists.linuxgazette.net'}
[...]

>   MTA = 'Postfix'

I'd change that, as you're using Exim.

HTH

-- 
"We used to quip that "password" is the most common password. Now 
 it's "password1." Who said users haven't learned anything about 
 security?"
  (Bruce Schneier, December 2006)
--
Mailman-Users mailing list
Mailman-Users@python.org
http://mail.python.org/mailman/listinfo/mailman-users
Mailman FAQ: http://wiki.list.org/x/AgA3
Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/
Unsubscribe: 
http://mail.python.org/mailman/options/mailman-users/archive%40jab.org

Security Policy: http://wiki.list.org/x/QIA9


[Mailman-Users] Virtual domain not quite working on HTTP (but fine on SMTP)

2009-06-17 Thread Rick Moen
Greetings, good people.  Problem summary:  After server rebuild, 
virtual hosts work for SMTP, but Mailman's Web pages are appearing
for the main host only and _not_ the virtual host.



Details:

I've had Mailman running on Debian (serving up mailing lists for both
"linuxmafia.com" and "lists.linuxgazette.net") since, oh, God was a
teenager, but a power spike destroyed my somewhat antique hardware in
April.  I hastily deployed Debian "lenny" 5.0 on a spare box the same
day, and then copied back down my latest backup data and madly worked to
recreate the prior config. 

That data restore including dropping back into place the former entire
/var/lib/mailman/lists/ tree (mailing list definitions), the 
/var/lib/mailman/archives/ tree, etc.  (As noted below, this data restore 
was correct to the extent of making Mailman able to handle both 
domains' mailing lists correctly concerning SMTP operation, and 
linuxmafia.com's mailing lists concerning Mailman Web pages.)


Relevant package versions:

:r! dpkg -l | egrep 'mailman|apache2-mpm-prefork|exim4-base'

ii  apache2-mpm-prefork   2.2.8-1Traditional 
model for Apache HTTPD
ii  exim4-base4.69-9 support files 
for all Exim MTA (v4) packages
ii  mailman   1:2.1.10~b3-1  Powerful, 
web-based mailing list manager

Things are oddly different from Pleistocene times when I did the job
before (not a complaint!).

After some fussing about concerning exim4/mailman integration, I
stumbled on details about POSTFIX_STYLE_VIRTUAL_DOMAINS and its use even
with non-Postfix MTAs.  (I put the required plumbing into
/etc/exim4/conf.d/*.  It works.)  I did read the Debian folks'
/usr/share/doc/mailman/README.Exim4.Debian , which includes in part:

  Here's a way to integrate mailman with Exim4 that will automatically
  play nice with mailman's virtual domains support and VERP. It does not
  require dedicating domain(s) to mailman.

  Configure your Mailman (in /etc/mailman/mm_cfg.py) with:

  MTA = 'Postfix'
  POSTFIX_ALIAS_CMD = '/bin/true'
  POSTFIX_MAP_CMD = 'chgrp Debian-exim'

  and list all your Mailman domains in "POSTFIX_STYLE_VIRTUAL_DOMAINS".

  Please note that the chgrp command above will not work when creating a
  list in the web interface: the user www-data will not be allowed to do
  this. You can circumvent this problem by creating new lists with the
  'newlist' command line command or using instead:
  POSTFIX_MAP_CMD = 'chmod o+r'
  This will allow local users (with shell access to the list server) to
  see the list of all Mailman mailing lists, but not much more.

I also noted what appeared to be good advice at
http://files.technomage.net/postfix_mailman.txt -- and, consequently, 
completed Exim integration by running /var/lib/mailman/bin/genaliases, 
and, lo!  /var/lib/mailman/data/{aliases|virtual-mailman} came into
existence, and Exim stopped generating errors.  More important, the
Exim/Mailman jointly [re-]started processing mail for the mailing lists
within both domains.  Life was good.  Almost.


There remains the matter of Mailman's Web pages:  Those for domain
linuxmafia.com are present.  (See: http://linuxmafia.com/mailman/listinfo/)
Those for domain lists.linuxgazette.net are not.  See:
http://lists.linuxgazette.net/mailman/listinfo/ -- as you'll notice,
Apache2 does recognise the domain.  The Apache document root for that
location, /var/www/gazette, has an .htaccess file in it, as follows:

  # cat /var/www/gazette/.htaccess 
  redirect 301 /index.html
  http://lists.linuxgazette.net/mailman/listinfo/

If I mv .htaccess to .htacces-save for diagnostic purposes, I _do_ 
see the contents of /var/www/gazette/ in my browser, so this is not 
an Apache vhost problem.


Here is what I imagine is the relevant part of my current
/var/lib/mailman/Mailman/mm_cfg.py :

  # Default domain for email addresses of newly created MLs
  DEFAULT_EMAIL_HOST = 'linuxmafia.com'
  #-
  # Default host for web interface of newly created MLs
  DEFAULT_URL_HOST   = 'linuxmafia.com'
  #-
  # Required when setting any of its arguments.
  add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
  add_virtualhost('lists.linuxgazette.net', 'lists.linuxgazette.net')
[...]
  # Uncomment if you use Postfix virtual domains, but be sure to
  # see /usr/share/doc/mailman/README.Debian first.
  # MTA='Postfix'
  MTA = 'Postfix'
  POSTFIX_ALIAS_CMD = '/bin/true'
  POSTFIX_MAP_CMD = 'chgrp Debian-exim'
  POSTFIX_STYLE_VIRTUAL_DOMAINS = ['linuxmafia.com', 'lists.linuxgazette.net']
  VIRTUAL_HOSTS = {'lists.linuxgazette.net':'lists.linuxgazette.net'}
  VIRTUAL_HOST_OVERVIEW = 1


Here is what I imagine is the relevant part of my current
/var/lib/mailman/Mailman/Default.py:

  
  # Virtual domains
  #

  # Set up your virtual host mappings here.  This is primaril