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

running a command with sudo

> On Tue, Apr 22, 2008 at 12:55:17AM +0100, Chris Lamb wrote:
>  > Alex Owen wrote:
>  >
>  > > The above should work... but read visudo man page...
>  >
>  > This is all totally pointless. Just append your line to /etc/sudoers in a
>  > live-initramfs hook: this is what it does itself, so it's difficult to see
>  > why you could have any qualms about doing so too.
Chris: I agree! see my first post in the thread: "In conclusion your
code looks OK!" refering to appending to /etc/sudoers. I was mearly
explaining how one can override with $EDITORS as there seemed to be
some confusion about how to achive that, and it can be a usefull
technique even if not in this case.

On 22/04/2008, Tzafrir Cohen <tzafrir.cohen at xorcom.com> wrote:
> That is: any better Debian-blessed way for a package to edit
>  /etc/sudoers ?
I do not think that there is any Debian-blessed way for a package to
edit /etc/sudoers. Infact I think it is prohibited under debian policy
section 10.7.

> I prefer to put my changes in packages and not in
>  "one-time" scripts, as this makes them also usable outside of the
>  specific environment of debian-live. And the whole point of Debian-Live
>  is to use unmodified Debian.

Probably the best way is to include instructions in the packages
README.Debian file.
I personally would not want a package to edit /etc/sudoers for me
though I'd be grateful for clear instructions in README.Debian.

The use of the package in debian-live is slightly different...
live-helper is there to generate a pre-configured debian system...
hence  use of a one time script is the most elagant way given all
these restrictions!

Anyway... that is my take on it!

Alex Owen

Reply to: