[systemd-devel] soft-reboot and service templates

Luca Boccassi luca.boccassi at gmail.com
Fri Jun 7 12:50:20 UTC 2024


On Fri, 7 Jun 2024 at 13:10, Thorsten Kukuk <kukuk at suse.com> wrote:
>
> On Fri, Jun 7, 2024 at 12:43 PM Luca Boccassi <luca.boccassi at gmail.com> wrote:
>
> > /run is expected though - if you want that, you need to bind mount it
> > explicitly. You normally don't want all of it, and the default
> > portable profile only picks the journal and dbus sockets and a couple
> > of other things, which is better:
> >
> > BindReadOnlyPaths=/dev/log /run/systemd/journal/socket
> > /run/systemd/journal/stdout
> > BindReadOnlyPaths=/etc/machine-id
> > BindReadOnlyPaths=-/etc/resolv.conf
> > BindReadOnlyPaths=/run/dbus/system_bus_socket
>
> Ok, but I still expect that, if sd_journal_print() works without
> additional service file entries before soft-reboot, it continues to
> work after soft-reboot, too. But I'm fine with adding the additional
> BindPaths to my service file.

Sounds like something we need to document:

https://github.com/systemd/systemd/pull/33244


More information about the systemd-devel mailing list