SPECS: nut.spec - reordered scripts

qboosh qboosh at pld-linux.org
Wed Oct 26 09:47:50 CEST 2005


Author: qboosh                       Date: Wed Oct 26 07:47:50 2005 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- reordered scripts

---- Files affected:
SPECS:
   nut.spec (1.97 -> 1.98) 

---- Diffs:

================================================================
Index: SPECS/nut.spec
diff -u SPECS/nut.spec:1.97 SPECS/nut.spec:1.98
--- SPECS/nut.spec:1.97	Tue Oct 25 23:17:00 2005
+++ SPECS/nut.spec	Wed Oct 26 09:47:45 2005
@@ -208,6 +208,22 @@
 %clean
 rm -rf $RPM_BUILD_ROOT
 
+%post
+/sbin/chkconfig --add ups
+if [ -f /var/lock/subsys/ups ]; then
+	/etc/rc.d/init.d/ups restart >&2
+else
+	echo "Run \"/etc/rc.d/init.d/ups start\" to start NUT ups daemon."
+fi
+
+%preun
+if [ "$1" = "0" ]; then
+	if [ -f /var/lock/subsys/ups ]; then
+		/etc/rc.d/init.d/ups stop >&2
+	fi
+	/sbin/chkconfig --del ups
+fi
+
 %pre common
 # move to trigger?
 if [ -n "`/usr/bin/getgid ups`" ] && [ "`/usr/bin/getgid ups`" = 121 ]; then
@@ -218,14 +234,6 @@
 %groupadd -g 76 ups
 %useradd -u 70 -d /usr/share/empty -s /bin/false -c "UPS Manager User" -g ups ups
 
-%post
-/sbin/chkconfig --add ups
-if [ -f /var/lock/subsys/ups ]; then
-	/etc/rc.d/init.d/ups restart >&2
-else
-	echo "Run \"/etc/rc.d/init.d/ups start\" to start NUT ups daemon."
-fi
-
 %post client
 /sbin/chkconfig --add upsmon
 if [ -f /var/lock/subsys/upsmon ]; then
@@ -234,14 +242,6 @@
 	echo "Run \"/etc/rc.d/init.d/upsmon start\" to start NUT upsmon daemon."
 fi
 
-%preun
-if [ "$1" = "0" ]; then
-	if [ -f /var/lock/subsys/ups ]; then
-		/etc/rc.d/init.d/ups stop >&2
-	fi
-	/sbin/chkconfig --del ups
-fi
-
 %preun client
 if [ "$1" = "0" ]; then
 	if [ -f /var/lock/subsys/upsmon ]; then
@@ -329,6 +329,9 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.98  2005/10/26 07:47:45  qboosh
+- reordered scripts
+
 Revision 1.97  2005/10/25 21:17:00  zawadaa
 - upsmon (nut-client) needs ups user! - ups usera moved to nut-common
 - STBR?
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SPECS/nut.spec?r1=1.97&r2=1.98&f=u




More information about the pld-cvs-commit mailing list