Hi, This looks very good and should work for me. Many thanks!
On Sun, Aug 25, 2024 at 6:57 AM Lorenzo <plore...@disroot.org> wrote: > Dear Mo Jun, > > I propose the following: > > * drop /lib/lsb/init-functions.d/40-runit > > * add /etc/runit/override-sysv.d/default-runit > > default-runit will set the policy about forwarding the > invoke-rc.d action to runscripts. The default policy will > be the same as now, but it will be possible to override it > for each script, so for example (for anacron) > > - /etc/runit/override-sysv.d/anacron.block --> always block > invoke-rc.d for anacron > - /etc/runit/override-sysv.d/anacron.runit --> always forward to > the anacron runscript, even if it's already managed by > runit-helper or trigger_sv > - /etc/runit/override-sysv.d/anacron.sysv --> always call the > sysvinit script for anarcon > > this way we could limit the signal-twice thing to runscript that > need it; for example, the anacron runscript in runit-services package > will create the /etc/runit/override-sysv.d/anacron.runit file so that > cronjobs are not skipped. > > to summarize, the difference from the current status will be: > > * the main policy script will be below /etc/ so the user can modify > default-runit and all changes will be persistent on upgrade > > * default policy tunable for each service, by touching files inside > /etc/runit/override-sysv.d/ > will be very convenient to create or remove those files with the > runscript > > * the policy will work only for invoke-rc.d calls, direct call > to /etc/init.d/foo is out of scope. This will create issue with > the few packages that call the script without using invoke-rc.d, > but the number is manageble (I will file bugs) and I think it's not > correct forbid the local admin to run a script in the system if he > wants to.. > > let me if will work for you. > > Regards, > Lorenzo > >