Accepting request 260515 from home:Ledest:misc

fix bashisms in pre/post scripts

OBS-URL: https://build.opensuse.org/request/show/260515
OBS-URL: https://build.opensuse.org/package/show/Base:System/nfs-utils?expand=0&rev=135
This commit is contained in:
Neil Brown 2014-11-09 22:34:50 +00:00 committed by Git OBS Bridge
parent 56601d6192
commit 35ecbc8e59
2 changed files with 9 additions and 2 deletions

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Sun Nov 09 19:34:00 UTC 2014 - Led <ledest@gmail.com>
- fix bashisms in pre/post scripts
-------------------------------------------------------------------
Wed Nov 5 00:48:09 UTC 2014 - nfbrown@suse.com

View File

@ -189,12 +189,14 @@ rm -rf $RPM_BUILD_ROOT
%pre -n nfs-client
useradd -r -c 'NFS statd daemon' \
-s /sbin/nologin -d /var/lib/nfs -g nogroup statd &> /dev/null || :
-s /sbin/nologin -d /var/lib/nfs -g nogroup statd > /dev/null 2>&1 || :
%service_add_pre nfs
%post -n nfs-client
chown statd:nogroup /var/lib/nfs
chown -R statd /var/lib/nfs/{state,sm,sm.bak} >& /dev/null || :
for i in state sm sm.bak; do
chown -R statd /var/lib/nfs/$i > /dev/null 2>&1 || :
done
### migrate from /var/lock/subsys
[ -d /run/nfs ] || mkdir /run/nfs
if [ -f /var/lock/subsys/nfs-rpc.idmapd ]; then