Hello Machu Just copy the current 0040-sudo hook to config/hooks/0040-sudo.hook.chroot and then customize it. At least that what I will do.
- Kristian Klausen ________________________________ Fra: Machu Chukov <m.chu...@gmx.de> Sendt: 6. oktober 2016 14:23:35 Til: debian-live@lists.debian.org Emne: Re: live-config hooks Ah, I think I got it. The scripts in {builddirectory}/config/hooks/ are executed the very last in chroot-stage. Placing a script in there, that alters the 0040-sudo provided by live-boot, would be the best way, to solve the problem. Correct? kind regards Machu Am 06.10.2016 um 14:01 schrieb Machu Chukov: > Hello everybody, > > I want to change the configuration of sudo in a debian live-system. > That's what live-config-hooks are made for, in this case > /lib/live/config/0040-sudo. But I want to configure sudo in a > different way, than it is made in this hook. I want to disable sudo > for all normal users, unless a specific boot-parameter is found in > /proc/cmdline. > > I'm not sure, if I fully understood the methods as conceived by > live-build/live-config: > > Normally I would edit the hook, that in the final images filesystem is > located in /lib/live/config/0040-sudo. But the problem is, that it is > installed automatically (as part of the live-config package) in > chroot-stage by live-build, correct? So at which point could I alter > it? I could revert the configuration made by > /lib/live/config/0040-sudo in a hook, that is executed later on, let's > say 2000-real-sudo-config. But to tolerate a false configuration and > revert it later does not seem very smart to me. Is there a better > solution to set configurations conflicting with those made by default > by the live-config hooks? Would e.g. my custom 0040-sudo, placed in > {builddirectory}/config/includes.chroot/lib/live/config/ overwrite the > 0040-sudo provided automatically by the live-config package? > > kind regards > > Machu >