]> git.pld-linux.org Git - packages/gearmand.git/commitdiff
correct scriptlets
authorElan Ruusamäe <glen@delfi.ee>
Wed, 27 Jan 2016 21:48:43 +0000 (23:48 +0200)
committerElan Ruusamäe <glen@delfi.ee>
Wed, 27 Jan 2016 21:48:43 +0000 (23:48 +0200)
gearmand.spec

index 68c1b203157a0fbc4dbfd3fc8ec463f94aaf1dfe..a46c9507a5c3a6db91d8e5136ca364dc1b900526 100644 (file)
@@ -149,26 +149,21 @@ rm -rf $RPM_BUILD_ROOT
 %groupadd -g 328 gearmand
 %useradd -u 328 -g gearmand -d / -s /sbin/nologin -c "Gearmand job server" gearmand
 
-%if 0
 %post
+test -e /var/log/gearmand.log || touch /var/log/gearmand.log
+/sbin/chkconfig --add gearmand
+%service gearmand restart
 %systemd_post gearmand.service
-if [ $1 = 1 ]; then
-       /sbin/chkconfig --add gearmand
-fi
-touch /var/log/gearmand.log
 
 %preun
-%systemd_preun gearmand.service
 if [ "$1" = 0 ] ; then
        %service gearmand stop
        /sbin/chkconfig --del gearmand
 fi
+%systemd_preun gearmand.service
 
 %postun
-%systemd_postun_with_restart gearmand.service
-%endif
-
-%postun
+%systemd_reload
 if [ "$1" = "0" ]; then
        %userremove gearmand
        %groupremove gearmand
This page took 0.142166 seconds and 4 git commands to generate.