Add missing rpm script for arcconf, nfs, local plugins.

This commit is contained in:
Gris Ge 2018-03-23 18:08:47 +08:00
parent 4472720e69
commit 3f57af82ed
1 changed files with 40 additions and 1 deletions

View File

@ -3,7 +3,7 @@
Name: libstoragemgmt
Version: 1.6.1
Release: 4%{?dist}
Release: 5%{?dist}
Summary: Storage array management library
Group: System Environment/Libraries
License: LGPLv2+
@ -405,6 +405,42 @@ if [ $1 -eq 0 ]; then
/usr/bin/systemctl try-restart %{name}.service >/dev/null 2>&1 || :
fi
# Need to restart lsmd if plugin is new installed or removed.
%post arcconf-plugin
if [ $1 -eq 1 ]; then
# New install.
/usr/bin/systemctl try-restart %{name}.service >/dev/null 2>&1 || :
fi
%postun arcconf-plugin
if [ $1 -eq 0 ]; then
# Remove
/usr/bin/systemctl try-restart %{name}.service >/dev/null 2>&1 || :
fi
# Need to restart lsmd if plugin is new installed or removed.
%post nfs-plugin
if [ $1 -eq 1 ]; then
# New install.
/usr/bin/systemctl try-restart %{name}.service >/dev/null 2>&1 || :
fi
%postun nfs-plugin
if [ $1 -eq 0 ]; then
# Remove
/usr/bin/systemctl try-restart %{name}.service >/dev/null 2>&1 || :
fi
# Need to restart lsmd if plugin is new installed or removed.
%post local-plugin
if [ $1 -eq 1 ]; then
# New install.
/usr/bin/systemctl try-restart %{name}.service >/dev/null 2>&1 || :
fi
%postun local-plugin
if [ $1 -eq 0 ]; then
# Remove
/usr/bin/systemctl try-restart %{name}.service >/dev/null 2>&1 || :
fi
%files
%defattr(-,root,root,-)
%doc README COPYING.LIB NEWS
@ -611,6 +647,9 @@ fi
%{_mandir}/man1/local_lsmplugin.1*
%changelog
* Fri Mar 23 2018 Gris Ge <fge@redhat.com> - 1.6.1-5
- Add missing rpm script for arcconf, nfs, local plugins.
* Thu Mar 22 2018 Gris Ge <fge@redhat.com> - 1.6.1-4
- Fix build on GCC 8