Overview

Request 1088562 accepted

- Move more packaging fixups in the fixlet script.

- Provide (Lua-based) file triggers and adapt systemd.spec accordingly (boo#1133764)
More specifically, file triggers handle automatically installations or updates
of files for sysusers, tmpfiles, hwdb, journal catalog, udev rules, sysctl and
binfmt.
Therefore it makes a bunch of systemd rpm macros (such as %udev_hwdb_update,
%udev_rules_update, %journal_catalog_update, %tmpfiles_create,
%sysusers_create and so on) not needed anymore. However before considering
simplifying your spec files beware that these changes are not available in SLE
yet and will probably never reach the current releases (latest one being
SLE15-SP5 as of this writing).
Macros dealing with unit restart/enabling (such as %systemd_pre,
%service_add_pre, %service_del_postun, ...) are still needed though. However
reloading of systemd instances (and thus restarting of units) are delayed
until the very end of the package install/update transaction and is now done
only once.
Nevertheless to fully take advantage of file triggers, users have to activate
a specific zypper transaction backend which is still considered as
experimental, see bsc#1041742 for details.
- Provide a (slighlty) customized version of systemd-update-helper. Some of the
systemd rpm macros rely now on the helper and delegate their work to it. Hence
we don't need to rebuild all packages anymore when the content of the rpm
macros must be updated/fixed.

- Drop an old fix for the persistent net rules (only needed on SLE). Factory
(fortunately) dropped the persistent net rule generator long time ago.

Loading...

Fabian Vogt's avatar

FWICT there's nothing which blocks those triggers from running during a transactional update and changing the running system. /proc is accessible, so sysctl and binfmt are modifiable...


Franck Bui's avatar
author source maintainer

Hmm... but it's always been the case, no ?

I don't think this PR is changing anything in this regard, or am I missing something ?


Fabian Vogt's avatar

FWICT sysctl.d changes are not applied at installation time yet


Fabian Vogt's avatar

Actually, this is already dealt with: I completely missed the if posix.access("/run/systemd/system") then check.


Fabian Vogt's avatar

Only part I'm not sure yet is the udev hwdb update. FWICT that reads from /etc and writes the hwdb into /etc, but it's possible that /etc contents are modified afterwards. Would systemd-hwdb-update.service run on the next boot?

That's not new with this SR though FWICT

Actually, I wonder whether the ConditionNeedsUpdate design works at all. It's just weird.


Dominique Leuenberger's avatar
+# File trigger definitions
+%if %{without filetriggers}
+%include %{SOURCE7}
+%endif

so SOURCE7 (the one including the triggers) is only included when NOT using file triggers? that seems backwards


Franck Bui's avatar
author source maintainer

Good catch Dominique, thanks a lot !

Request History
Franck Bui's avatar

fbui created request

- Move more packaging fixups in the fixlet script.

- Provide (Lua-based) file triggers and adapt systemd.spec accordingly (boo#1133764)
More specifically, file triggers handle automatically installations or updates
of files for sysusers, tmpfiles, hwdb, journal catalog, udev rules, sysctl and
binfmt.
Therefore it makes a bunch of systemd rpm macros (such as %udev_hwdb_update,
%udev_rules_update, %journal_catalog_update, %tmpfiles_create,
%sysusers_create and so on) not needed anymore. However before considering
simplifying your spec files beware that these changes are not available in SLE
yet and will probably never reach the current releases (latest one being
SLE15-SP5 as of this writing).
Macros dealing with unit restart/enabling (such as %systemd_pre,
%service_add_pre, %service_del_postun, ...) are still needed though. However
reloading of systemd instances (and thus restarting of units) are delayed
until the very end of the package install/update transaction and is now done
only once.
Nevertheless to fully take advantage of file triggers, users have to activate
a specific zypper transaction backend which is still considered as
experimental, see bsc#1041742 for details.
- Provide a (slighlty) customized version of systemd-update-helper. Some of the
systemd rpm macros rely now on the helper and delegate their work to it. Hence
we don't need to rebuild all packages anymore when the content of the rpm
macros must be updated/fixed.

- Drop an old fix for the persistent net rules (only needed on SLE). Factory
(fortunately) dropped the persistent net rule generator long time ago.


Factory Auto's avatar

factory-auto added opensuse-review-team as a reviewer

Please review sources


Factory Auto's avatar

factory-auto accepted review

Check script succeeded


Dominique Leuenberger's avatar

dimstar accepted review


Saul Goodman's avatar

licensedigger accepted review

ok


Staging Bot's avatar

staging-bot set openSUSE:Factory:Staging:A as a staging project

Being evaluated by staging project "openSUSE:Factory:Staging:A"


Staging Bot's avatar

staging-bot accepted review

Picked "openSUSE:Factory:Staging:A"


Dominique Leuenberger's avatar

dimstar_suse accepted review

Staging Project openSUSE:Factory:Staging:A got accepted.


Dominique Leuenberger's avatar

dimstar_suse approved review

Staging Project openSUSE:Factory:Staging:A got accepted.


Dominique Leuenberger's avatar

dimstar_suse accepted request

Staging Project openSUSE:Factory:Staging:A got accepted.

openSUSE Build Service is sponsored by