]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
rpm: cleanup: drop %service_del_postun_without_restart
authorNathan Cutler <ncutler@suse.com>
Tue, 29 Sep 2020 13:46:35 +0000 (15:46 +0200)
committerNathan Cutler <ncutler@suse.com>
Wed, 21 Jul 2021 16:14:23 +0000 (18:14 +0200)
SUSE needs %service_del_postun (with or without restart) *only* if there
is a possibility that the RPM containing the unit file will be upgraded
from a version that packaged SysVinit scripts instead of systemd unit
files. (Which is not the case here.)

Signed-off-by: Nathan Cutler <ncutler@suse.com>
(cherry picked from commit f69aa5abfb2279919026144aa51e3c72f593e935)

Conflicts:
ceph.spec.in

ceph.spec.in

index 4183a7d87e052c26b363411b7a5eafd564835f41..891105b6babdfad886841ac05532ce62b7f209d3 100644 (file)
@@ -1444,12 +1444,7 @@ fi
 
 %postun base
 /sbin/ldconfig
-%if 0%{?suse_version}
-%service_del_postun_without_restart ceph.target
-%endif
-%if 0%{?fedora} || 0%{?rhel}
 %systemd_postun ceph.target
-%endif
 if [ $1 -ge 1 ] ; then
   # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to
   # "yes". In any case: if units are not running, do not touch them.
@@ -1585,12 +1580,7 @@ fi
 %endif
 
 %postun mds
-%if 0%{?suse_version}
-%service_del_postun_without_restart ceph-mds@\*.service ceph-mds.target
-%endif
-%if 0%{?fedora} || 0%{?rhel}
 %systemd_postun ceph-mds@\*.service ceph-mds.target
-%endif
 if [ $1 -ge 1 ] ; then
   # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to
   # "yes". In any case: if units are not running, do not touch them.
@@ -1659,12 +1649,7 @@ fi
 %endif
 
 %postun mgr
-%if 0%{?suse_version}
-%service_del_postun_without_restart ceph-mgr@\*.service ceph-mgr.target
-%endif
-%if 0%{?fedora} || 0%{?rhel}
 %systemd_postun ceph-mgr@\*.service ceph-mgr.target
-%endif
 if [ $1 -ge 1 ] ; then
   # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to
   # "yes". In any case: if units are not running, do not touch them.
@@ -1785,12 +1770,7 @@ fi
 %endif
 
 %postun mon
-%if 0%{?suse_version}
-%service_del_postun_without_restart ceph-mon@\*.service ceph-mon.target
-%endif
-%if 0%{?fedora} || 0%{?rhel}
 %systemd_postun ceph-mon@\*.service ceph-mon.target
-%endif
 if [ $1 -ge 1 ] ; then
   # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to
   # "yes". In any case: if units are not running, do not touch them.
@@ -1842,12 +1822,7 @@ fi
 %endif
 
 %postun -n rbd-mirror
-%if 0%{?suse_version}
-%service_del_postun_without_restart ceph-rbd-mirror@\*.service ceph-rbd-mirror.target
-%endif
-%if 0%{?fedora} || 0%{?rhel}
 %systemd_postun ceph-rbd-mirror@\*.service ceph-rbd-mirror.target
-%endif
 if [ $1 -ge 1 ] ; then
   # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to
   # "yes". In any case: if units are not running, do not touch them.
@@ -1900,12 +1875,7 @@ fi
 %endif
 
 %postun radosgw
-%if 0%{?suse_version}
-%service_del_postun_without_restart ceph-radosgw@\*.service ceph-radosgw.target
-%endif
-%if 0%{?fedora} || 0%{?rhel}
 %systemd_postun ceph-radosgw@\*.service ceph-radosgw.target
-%endif
 if [ $1 -ge 1 ] ; then
   # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to
   # "yes". In any case: if units are not running, do not touch them.
@@ -1966,12 +1936,7 @@ fi
 %endif
 
 %postun osd
-%if 0%{?suse_version}
-%service_del_postun_without_restart ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target
-%endif
-%if 0%{?fedora} || 0%{?rhel}
 %systemd_postun ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target
-%endif
 if [ $1 -ge 1 ] ; then
   # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to
   # "yes". In any case: if units are not running, do not touch them.