Subject: Re: pkgsrc.txt and sudo
To: Roland Illig <rillig@NetBSD.org>
From: Aleksey Cheusov <cheusov@tut.by>
List: netbsd-docs
Date: 05/01/2007 19:58:01
> Aleksey Cheusov wrote:
>> I'm not sure this mailing list is a right place for reporting
>> bugs(?) in pkgsrc documentation.
>> pkgsrc.txt:
>> 8.13. Using 'sudo' with pkgsrc
>> When installing packages as non-root user su(1) feature of
>> pkgsrc, it can become annoying to type in the root password for
>> each required package installed. To avoid this, the sudo
>> package can be used, which does password caching over a limited
>> time. To use it, install sudo (either as binary package or from
>> security/sudo) and then put the following into your /etc
>> /mk.conf:
>> .if exists(${LOCALBASE}/bin/sudo)
>> SU_CMD= ${LOCALBASE}/bin/sudo /bin/sh -c
>> .endif
> You need to define LOCALBASE _before_ including this snippet. I'm
> updating the pkgsrc guide to say that.
Normally LOCALBASE is defined in mk/default/mk.conf.
Why not to change this to
.if exists(/usr/pkg/bin/sudo)
SU_CMD=/usr/pkg/bin/sudo /bin/sh -c
.endif
Or better why not just remove this .exist condition and
to keep
SU_CMD= /usr/local/bin/sudo /bin/sh -c
Do you also think that there is no cyclic dependency here
and that prompt for a passowrd (for su when sudo is uninstalled)
is ok in case of massive build?
--
Best regards, Aleksey Cheusov.