[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#243918: apache adds webmaster alias but forget newaliases



On Thu, Apr 15, 2004 at 05:12:14PM +0100, Matthew Wilcox wrote:
> On Thu, Apr 15, 2004 at 05:56:28PM +0200, Jeroen van Wolffelaar wrote:
> > /etc/aliases is the source file for the system mail aliases (e.g.,
> > postmaster, usenet, etc.), it is the one which the sysadmin and postinst
> > scripts may edit. After /etc/aliases is edited the program or human
> > editing it must call newaliases. All MTA packages must come with a
> > newaliases program, even if it does nothing, but older MTA packages did
> > not do this so programs should not fail if newaliases cannot be found.
> > Note that because of this, all MTA packages must have Provides,
> > Conflicts and Replaces: mail-transport-agent control file fields.
> 
> That's great, but how can we possibly do that?  If you know what path
> newaliases has, you can simply do if [ -x $NEWALIASES ] $NEWALIASES
> I suppose we could do something like:
> 
> for i in /bin /sbin /usr/bin /usr/sbin /usr/local/bin /usr/local/sbin; do
> 	if [ -x $i/newaliases] $i/newaliases
> done

You can simply run it, and ignore the exit code? No need to bother first
checking whether it exists, you can simply attempt to run it. Since
policy says failure of newaliasas is to be ignored, you weren't doing
anything witht the exit code anyway.

--Jeroen

-- 
Jeroen van Wolffelaar
Jeroen@wolffelaar.nl (also for Jabber & MSN; ICQ: 33944357)
http://Jeroen.A-Eskwadraat.nl



Reply to: