On Sun, Dec 14, 2025 at 08:47:37AM +0100, Niels Thykier wrote:
Marc Haber:
On Sat, Dec 13, 2025 at 06:38:15PM +0100, Niels Thykier wrote:
To my knowledge, people use `systemd-tmpfiles` for creating/chown file system items not shipped in the `.deb`.

And how about systemd-sysusers?


I am not sure what you mean with this question. The debhelper stack has support for `systemd-sysusers` via `dh_installsysusers`, and the snippets are aligned with `dh_installtmpfiles` to ensure they are run in the proper order.

For example, mariadb. This is not a clear example of perfect usage of adduser, but it creates its user in preinst, then mkdirs /var/lib/mysql and /var/log/mysql and chowns the directories to that user.

exim does the same in postinst: adduser, install -d /var/log/exim4, /var/sppol/exim4, /var/spool/exim4/*.

How would those package do their job with plain debhelper, systemd-sysusers and systemd-tmpfiles? Would those package have to list their certainly non-temporary data and log directories in tmpfiles.d?

What if those directories need to be filled with some preliminary data before the daemon can be started?

concrete problem/case you are observing, so I can engage in that rather than having to guess and ending up solving the problem/case you did not have. :)

Sorry for being clear.

Greetings
Marc


--
-----------------------------------------------------------------------------
Marc Haber         | "I don't trust Computers. They | Mailadresse im Header
Leimen, Germany    |  lose things."    Winona Ryder | Fon: *49 6224 1600402
Nordisch by Nature |  How to make an American Quilt | Fax: *49 6224 1600421

Reply via email to