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

Bug#1039142: busybox: ships sysv-init script without systemd unit



Control: tag -1 + help

On Sun, 25 Jun 2023 23:20:24 +0100 bluca@debian.org wrote:
Package: busybox
Severity: important
User: bluca@debian.org
Usertags: missing-systemd-service

Dear Maintainer(s),

busybox has been flagged by Lintian as shipping a sysv-init script
without a corresponding systemd unit file. The default init system in
Debian is systemd, and so far this worked because a transitional
sysv-init-to-unit generator was shipped by systemd. This is in the
process of being deprecated and will be removed by the time Trixie
ships, so the remaining packages that ship init scripts without
systemd units will stop working.

There are various advantages to using native units, for example the
legacy generator cannot tell the different between a oneshot service
and a long running daemon. Also, sanboxing and security features
become available for services. For more information, consult the
systemd documentation:
https://www.freedesktop.org/software/systemd/man/systemd.unit.html

You can find the Lintian warning here:

https://lintian.debian.org/sources/busybox

This site can't be found.  But it's ok.

So in current state, only udhcpd lacks systemd file.  So I tried to
provide one.  The initscript for udhcpd checks for UDHCPD_ENABLED=yes/no
in /etc/default/udhcpd and does nothing if it is not enabled, which
is the default.  Since there's no way in systemd to check for that
(well, there is, with ExecConditional, but it ugly at best), I thought
to ship udhcpd.service not enabled by default.  Except it doesn't
work.

With just dh_installsystemd --no-enable, it is still started.
With dh_installsystemd --no-enable --no-start, it is started
as well, - apparently because initscript is started.  Also,
with --no-enable --no-start, it is not restarted on upgrades
if enabled locally.

After doing several iterations, I decided to abandon this attempt, -
it just does not work, and I've no time to fight with the tools.

If someone has a working recipe for all this madness, please
share a patch for d/rules.

Tagging with "help" for now.

Thanks,

/mjt


Reply to: