Daniel Higgins wrote:
i have, it works nicely. except that it's less than ideal if you're trying
to automate the login/aliases creation process from a separate box whitout
too much hassle.
I guess you are referring to "A simpler method might be to use
"john@domain_i_host.com: jo...@hotmail.com" in an aliases file..."
beside creating tons of gay php scripts (or whatever you prefer) that runs
Even that is tricky when dealing with the permissions of the web
server writting into etc/aliases/*.
on an apache server, the other solution is implementing an ssh client in
your controlling application... not quite an easy task (well, maybe easy,
but certainly not something you can do in a few minutes)
For the benefit of anyone else struggling with a solution to this...
% cat update_alias
#!/bin/sh
ssh -f mail.host.com "echo \"$1: $2\" >/etc/courier/aliases/$1; \
makealiases; courier restart"
invoked as "update_alias john@domain_i_host.com jo...@hotmail.com"
from a remote machine by root, or some user who can write into
etc/aliases and can also pull a "courier restart". Untested and
the courier restart part may be not be needed in this case, and
it may have to be a tab between the "$1: $2" (then use echo -e).
--markc