fix post and postun error
This commit is contained in:
parent
e4c92bb330
commit
0c673a1add
20
rinetd.spec
20
rinetd.spec
@ -1,7 +1,7 @@
|
|||||||
%define with_systemd 1
|
%define with_systemd 1
|
||||||
Name: rinetd
|
Name: rinetd
|
||||||
Version: 0.62
|
Version: 0.62
|
||||||
Release: 1
|
Release: 2
|
||||||
Summary: TCP Redirection Server
|
Summary: TCP Redirection Server
|
||||||
License: GPL-2.0-or-later
|
License: GPL-2.0-or-later
|
||||||
URL: http://www.boutell.com/rinetd/
|
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
|
install -m 644 %SOURCE2 %{buildroot}/etc/logrotate.d/rinetd
|
||||||
|
|
||||||
%post
|
%post
|
||||||
%if %{with_systemd}
|
%systemd_post %{name}.service
|
||||||
%service_add_post %{name}.service
|
|
||||||
%else
|
%preun
|
||||||
%{fillup_and_insserv rinetd}
|
%systemd_preun %{name}.service
|
||||||
%endif
|
|
||||||
|
|
||||||
%postun
|
%postun
|
||||||
%if %{with_systemd}
|
%systemd_postun_with_restart %{name}.service
|
||||||
%service_del_postun %{name}.service
|
|
||||||
%else
|
|
||||||
%{insserv_cleanup}
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%defattr(-, root, root)
|
%defattr(-, root, root)
|
||||||
@ -84,5 +79,8 @@ install -m 644 %SOURCE2 %{buildroot}/etc/logrotate.d/rinetd
|
|||||||
/usr/sbin/rinetd
|
/usr/sbin/rinetd
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Sat 28 Aug 2021 wangyue <wangyue92@huawei.com> - 0.62-2
|
||||||
|
- fix post and postun error
|
||||||
|
|
||||||
* Fri May 7 2021 baizhonggui <baizhonggui@huawei.com> - 0.62-1
|
* Fri May 7 2021 baizhonggui <baizhonggui@huawei.com> - 0.62-1
|
||||||
- package init
|
- package init
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user