drop obsolete workaround in scriptlet

The bug with daemon-reload was fixed a long time ago.
The direct invocation of 'systemctl daemon-reload' with no redirect of
errors to /dev/null causes a user-visible message when installing into a chroot:

  Running scriptlet: chrony-4.2-4.fc37.x86_64     320/334
System has not been booted with systemd as init system (PID 1). Can't operate.
Failed to connect to bus: Host is down
  ...

Related: #2051441
This commit is contained in:
Zbigniew Jędrzejewski-Szmek 2022-02-16 08:10:11 +00:00 committed by Miroslav Lichvar
parent 02c3150f76
commit 0dfb022f40

View File

@ -161,8 +161,6 @@ getent passwd chrony > /dev/null || /usr/sbin/useradd -r -g chrony \
: :
%post %post
# workaround for late reload of unit file (#1614751)
%{_bindir}/systemctl daemon-reload
# migrate from chrony-helper to sourcedir directive # migrate from chrony-helper to sourcedir directive
if test -a %{_libexecdir}/chrony-helper; then if test -a %{_libexecdir}/chrony-helper; then
grep -qi 'sourcedir /run/chrony-dhcp$' %{_sysconfdir}/chrony.conf 2> /dev/null || \ grep -qi 'sourcedir /run/chrony-dhcp$' %{_sysconfdir}/chrony.conf 2> /dev/null || \