[systemd-devel] Prioritize the /etc configuration over /usr/lib also with .include
Pavel Raiskup
praiskup at redhat.com
Tue Sep 16 04:21:30 PDT 2014
Hi,
consider the situation that admin has /etc/systemd/system/a.service, which
includes via .include the /usr/lib/systemd/system/a.service. Then in our
case there exists also packaged /usr/lib/systemd/system/a.service.d/ with
existing drop-in. In this case - the setup from /etc/ is beaten by
drop-in files from /usr/lib. Reproducer is in Red Hat Bugzilla [1].
I would expect that parser starts at /etc/systemd/*/*.service, which
invokes the .include ~> so '/usr/lib/*/*.service is parsed, then
'/usr/lib/*/*.service.d', then remaining part of '/etc/*/*.service is
parsed and as the last step, the '/etc/*/*.service.d/' dropins should be
done.
The use-case to make it complete: I would like to have the .include
supported just for compatibility with older admin's settings. Then I
would like to install two service files 'a.service' and 'a at .service', both
hardlinked (ideally). The 'a.service' would diverge from 'a at .service'
just by e.g. /usr/lib/systemd/a.service/50-default.conf settings.
[1] https://bugzilla.redhat.com/show_bug.cgi?id=1141824
Pavel
More information about the systemd-devel
mailing list