diff --git a/rinetd.spec b/rinetd.spec index bcac783aef80ed750d9cbe32bb6f6b846acea0cf..1650edaeda6675743dcc891f3d9ac1b6d019b9b8 100644 --- a/rinetd.spec +++ b/rinetd.spec @@ -1,7 +1,7 @@ %define with_systemd 1 Name: rinetd Version: 0.62 -Release: 1 +Release: 2 Summary: TCP Redirection Server License: GPL-2.0-or-later URL: http://www.boutell.com/rinetd/ @@ -56,18 +56,13 @@ install -m 644 rinetd.8 %{buildroot}%_mandir/man8 install -m 644 %SOURCE2 %{buildroot}/etc/logrotate.d/rinetd %post -%if %{with_systemd} -%service_add_post %{name}.service -%else -%{fillup_and_insserv rinetd} -%endif +%systemd_post %{name}.service + +%preun +%systemd_preun %{name}.service %postun -%if %{with_systemd} -%service_del_postun %{name}.service -%else -%{insserv_cleanup} -%endif +%systemd_postun_with_restart %{name}.service %files %defattr(-, root, root) @@ -84,5 +79,8 @@ install -m 644 %SOURCE2 %{buildroot}/etc/logrotate.d/rinetd /usr/sbin/rinetd %changelog +* Sat 28 Aug 2021 wangyue - 0.62-2 +- fix post and postun error + * Fri May 7 2021 baizhonggui - 0.62-1 - package init