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

Re: Bug#739657: gnuhealth-server: fails to install: gnuhealth-server.postinst: sudo: not found



Hi Emilien,

On Sun, Feb 23, 2014 at 11:29:16PM +0100, Karsten Hilbert wrote:
> > OK, but why?
> > What I'm missing so far is an explanation on why we shouldn't use sudo for
> > this use-case.
> 
> I have heard the following argument from among Debian Devs:
> 
> su is included with any installation (unless
> forcefully removed) while sudo is optional

+1
 
> However, I don't feel depending on sudo is
> the End of The World.

I agree that it is not the end of the world.

> Also, your characterization
> 
> > Following the Unix philosophy of using a collection of specialized small
> > tools that do one thing best, when performing an action as another user it
> > seems to be the correct thing to use a tool that "execute a command as
> > another user" rather than one whose primary goal is "change user ID or
> > become superuser"
> 
> seems fairly succinct.

As I said I personally regard the manpage as some unfortunate wording here.
I learned `su` as "switch user" with the reasonable default to switch to
UID=0 (== root) but rather as a general means to switch to *any* user at
a given system and as the manpage perhaps less prominently but obviosly as
first option says it has an option

       -c, --command COMMAND
           Specify a command that will be invoked by the shell

My preference for su is that it is basic simple and you do not need to
install an extra package.  In contrast to su my perception of sudo was
always that by some reasonable confirguration you can give some fine
grained permissions to enable users becoming different roles by just
knowing their own password or a dedicated sudo password.  I personally
never used it to execute a command but only to become a different user
in a login shell and than do things.  This is exactly the inverse usage
as it is written in the manpage.  It simply might be me but since I
might have the wrong guut feeling I would like you to dig for other
resources (like some look into /var/lib/dpkg/info or simply asking at
debian-mentors@lists.debian.org what people might think there).

I think both solutions are OK if they are working but I personally would
definitely use the su-solution and would not spend a slight moment to
think about sudo.

Kind regards

      Andreas.

-- 
http://fam-tille.de


Reply to: