summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNarayan Desai <desai@mcs.anl.gov>2005-11-30 22:37:07 +0000
committerNarayan Desai <desai@mcs.anl.gov>2005-11-30 22:37:07 +0000
commit276e381a86ae5fa6aa7df51efae98e8d958db0d0 (patch)
treec3340c17c3d8bb4e32ab46522ba8b2defdf6ebd2
parentbb21a4c4a0956f0a5ce4cd5cbecee515ada4b936 (diff)
downloadbcfg2-276e381a86ae5fa6aa7df51efae98e8d958db0d0.tar.gz
bcfg2-276e381a86ae5fa6aa7df51efae98e8d958db0d0.tar.bz2
bcfg2-276e381a86ae5fa6aa7df51efae98e8d958db0d0.zip
add compat code for sles
2005/11/30 15:21:43-06:00 anl.gov!desai switch to backwards compatible init script (Logical change 1.376) git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@1583 ce84e21b-d406-0410-9b95-82705330c041
-rw-r--r--debian/bcfg2-server.init12
1 files changed, 10 insertions, 2 deletions
diff --git a/debian/bcfg2-server.init b/debian/bcfg2-server.init
index 311889ba0..83ed71f6c 100644
--- a/debian/bcfg2-server.init
+++ b/debian/bcfg2-server.init
@@ -11,12 +11,20 @@ PIDFILE=/var/tmp/bcfg2-xmlrpc.pid
case "$1" in
start)
echo -n "Starting Bcfg2Server: "
- start-stop-daemon --make-pidfile --pidfile "${PIDFILE}" -b -S --startas /usr/sbin/Bcfg2Server
+ if [ -f "/etc/SuSE-release" ] ; then
+ /sbin/start_daemon -p "${PIDFILE}" /usr/sbin/Bcfg2Server
+ else:
+ /sbin/start-stop-daemon -p "${PIDFILE}" -b -S -x /usr/sbin/Bcfg2Server
+ fi
echo "Bcfg2Server"
;;
stop)
echo -n "Stopping Bcfg2Server: "
- start-stop-daemon --pidfile "${PIDFILE}" -K /usr/sbin/Bcfg2Server
+ if [ -f "/etc/SuSE-release" ] ; then
+ /sbin/killproc -p "${PIDFILE}" /usr/sbin/Bcfg2Server
+ else
+ /sbin/start-stop-daemon -p "${PIDFILE}" -K /usr/sbin/Bcfg2Server
+ fi
echo done
;;
restart)