Re: packages.debian.org & qmail (was Re: Using CVS for package development)

1997-06-02 Thread Tom Lees
On Fri, 30 May 1997, Philip Hands wrote:

> What were you trying to achieve ? --- it might be simpler than you think.
> 
> I just discovered that most of my alias handling under qmail was drivel, and 
> could be dome much more simply.
> 
> > If someone wants to spend some time on a simple mailer hack, you can
> > make this work. 
> 
> If you want mail to, for instance:
> 
>   [EMAIL PROTECTED]

IIRC you can also alias an entire domain (packages.debian.org) to one user
(how lists.debian.org is currently done). So [EMAIL PROTECTED]
gets translated to, say bruce-packages-rsync.

Then, ~bruce/.qmail-packages will execute a script to process it, or you
can have .qmail-packages files for each pkg if you are worried about
speed.

-- 
Tom Lees <[EMAIL PROTECTED]>http://www.lpsg.demon.co.uk/
PGP ID 87D4D065, fingerprint 2A 66 86 9D 02 4D A6 1E  B8 A2 17 9D 4F 9B 89 D6
finger [EMAIL PROTECTED] for full public key (also available on keyservers)


--
TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to
[EMAIL PROTECTED] . 
Trouble?  e-mail to [EMAIL PROTECTED] .



Re: packages.debian.org & qmail (was Re: Using CVS for package development)

1997-06-01 Thread Philip Hands
> (1) user-map [if all package maintainers are local]

If you just want to be delivering mail to @packages.debian.org 
(rather than -@packages.debian.org), you can deliver 
to remote addresses with:

In users/assign, create one line per package:

 =:alias:70:65534:/var/qmail/alias:+:fwd-:

so in the case of my rsync package, that would be:

 =rsync:alias:70:65534:/var/qmail/alias:+:[EMAIL PROTECTED]:

and in ~alias/.qmail+fwd-default:

 |forward "$EXT2"

If you want to deal with mail to e.g.  [EMAIL PROTECTED] then it 
is more complicated.

Cheers, Phil.



--
TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to
[EMAIL PROTECTED] . 
Trouble?  e-mail to [EMAIL PROTECTED] .



Re: packages.debian.org & qmail (was Re: Using CVS for package development)

1997-06-01 Thread Raul Miller
On May 29, Bruce Perens wrote
> I must admit to not understanding what that qmail alias file is for.
> I do _all_ of my aliases with .qmail-* files .
> 
> What I was trying to achieve was to have qmail forward a message without
> messing around with the headers any more than necessary. Thus, I wanted
> to have a .qmail-packages-default file to handle the packages.debian.org
> domain, and that would look up the package name and map it to the maintainer
> address, and remail messages to the maintainer. This is not a terribly
> complicated hack, but I got busy.

I don't understand why you need to use RFC822 style addresses here?
You've got a message in-transit, so RFC821 seems more appropriate.

Furthermore, qmail parses the destination addresses and stuffs
it into various environmental variables, so parsing the dest address
shouldn't be an issue.

And, of course, identifying the proper smtp destination address for
the package maintainer is something that should be done at the time
the database is populated, not every time a message hits the system.

Given these conditions, I can think of at least three different ways
of implementing the forwarding:

(1) user-map [if all package maintainers are local]
(2) db lookup from -default
(and of course there's lots of ways to implement db)
(3) ~aliase/.q*

[There's more ways .. you could generate an account for each
package, ferinstance.]

-- 
Raul


--
TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to
[EMAIL PROTECTED] . 
Trouble?  e-mail to [EMAIL PROTECTED] .



Re: packages.debian.org & qmail (was Re: Using CVS for package development)

1997-05-30 Thread Carey Evans
Philip Hands <[EMAIL PROTECTED]> writes:

[snip]

> That seems simple enough.
> 
> I think your best bet is this:
> 
> 1) make sure control/locals does not contain packages.debian.org

But make sure it's in control/rcpthosts, of course.

> add this line to control/virtualdomains:
>   packages.debian.org:alias-packages
> 
> create ~alias/.qmail-packages-default, containing:
>   |forward "`/usr/local/bin/pkg2maint $EXT2`"

I would prefer  |forward "`/usr/local/bin/pkg2maint "$EXT2"`"  for
security.

> write /usr/local/bin/pkg2maint, which is a program that takes a
> package name, and puts the maintainers e-mail address on its STDOUT.
> 
> The only extra thing to have pkg2maint do is output an address that
> will cause the mail to bounce if the maintainer cannot be found
> ([EMAIL PROTECTED] might work)

A better way to bounce when a maintainer is not found would be to do
something like  |/usr/local/bin/pkgforward "$EXT2"  where pkgforward
execs qmail's forward if a maintainer is found, or prints "unknown
package" or "maintainer not found" as appropriate and returns 100.

If you've got 1000 or so spare inodes, you could just make a
~alias/.qmail-package-packagename for each package, containing
"&[EMAIL PROTECTED]" or whatever.

If packages.debian.org is really master.debian.org, you could use
users/assign to map "packages-packagename" to "maintername".

If you don't want to worry about unescaping the various formats of
email addresses, add the appropriate Resent-... and Delivered-To:
(from DTLINE) headers, set some env. vars and pipe the resulting
message into qmail-inject, telling it to get its recipients from the
message headers.

I could probably be persuaded to write this...  :-)

-- 
Carey Evans  <*>  [EMAIL PROTECTED]

"Lies, damn lies, and computer documentation."


--
TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to
[EMAIL PROTECTED] . 
Trouble?  e-mail to [EMAIL PROTECTED] .



Re: packages.debian.org & qmail (was Re: Using CVS for package development)

1997-05-30 Thread Philip Hands
> What I was trying to achieve was to have qmail forward a message without
> messing around with the headers any more than necessary. Thus, I wanted
> to have a .qmail-packages-default file to handle the packages.debian.org
> domain, and that would look up the package name and map it to the maintainer
> address, and remail messages to the maintainer. This is not a terribly
> complicated hack, but I got busy.

That seems simple enough.

I think your best bet is this:

1) make sure control/locals does not contain packages.debian.org

add this line to control/virtualdomains:

  packages.debian.org:alias-packages


create ~alias/.qmail-packages-default, containing:

  |forward "`/usr/local/bin/pkg2maint $EXT2`"



write /usr/local/bin/pkg2maint, which is a program that takes a package name, 
and puts the maintainers e-mail address on its STDOUT.

The only extra thing to have pkg2maint do is output an address that will cause 
the mail to bounce if the maintainer cannot be found 
([EMAIL PROTECTED] might work)

Anyone already have the pkg2maint code already written ?

Cheers, Phil.




--
TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to
[EMAIL PROTECTED] . 
Trouble?  e-mail to [EMAIL PROTECTED] .



Re: packages.debian.org & qmail (was Re: Using CVS for package development)

1997-05-30 Thread Bruce Perens
I must admit to not understanding what that qmail alias file is for.
I do _all_ of my aliases with .qmail-* files .

What I was trying to achieve was to have qmail forward a message without
messing around with the headers any more than necessary. Thus, I wanted
to have a .qmail-packages-default file to handle the packages.debian.org
domain, and that would look up the package name and map it to the maintainer
address, and remail messages to the maintainer. This is not a terribly
complicated hack, but I got busy.

Thanks

Bruce
-- 
Bruce Perens K6BP   [EMAIL PROTECTED]   510-215-3502
Finger [EMAIL PROTECTED] for PGP public key.
PGP fingerprint = 88 6A 15 D0 65 D4 A3 A6  1F 89 6A 76 95 24 87 B3 


--
TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to
[EMAIL PROTECTED] . 
Trouble?  e-mail to [EMAIL PROTECTED] .



packages.debian.org & qmail (was Re: Using CVS for package development)

1997-05-30 Thread Philip Hands
[EMAIL PROTECTED] said:
> I had problems making it work because darned qmail won't parse a full
> RFC822 address on the command line

What were you trying to achieve ? --- it might be simpler than you think.

I just discovered that most of my alias handling under qmail was drivel, and 
could be dome much more simply.

> If someone wants to spend some time on a simple mailer hack, you can
> make this work. 

If you want mail to, for instance:

  [EMAIL PROTECTED]

to get sent to:

  [EMAIL PROTECTED]

Assuming that packages.debian.org is just an alternative name for master, then 
you just need to generate a couple of lines in /var/qmail/users/assign for 
each package, like this:

=rsync:philh:952:800:/home/Debian/philh:::
+rsync-:philh:952:800:/home/Debian/philh:-::

Having to put the UID GID numbers in the file is a pain, but that can be 
avoided, with one extra ~alias file.

Cheers, Phil.



--
TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to
[EMAIL PROTECTED] . 
Trouble?  e-mail to [EMAIL PROTECTED] .