]> git.pld-linux.org Git - packages/Zope.git/commitdiff
- initial rev
authormis <mis@pld-linux.org>
Thu, 6 Sep 2001 13:42:34 +0000 (13:42 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    Zope-zserver.sh -> 1.1
    Zope.init -> 1.1

Zope-zserver.sh [new file with mode: 0644]
Zope.init [new file with mode: 0644]

diff --git a/Zope-zserver.sh b/Zope-zserver.sh
new file mode 100644 (file)
index 0000000..b7a343a
--- /dev/null
@@ -0,0 +1,21 @@
+#! /bin/sh
+# $Id$
+
+PATH="/bin:/usr/bin:/usr/sbin:/sbin"
+ZOPE_HOME=/usr/lib/zope
+INSTANCE_HOME=/var/lib/zope
+INST_HOME=${INSTANCE_HOME}
+CLIENT_HOME=/var/lib/zope
+
+export INST_HOME INSTANCE_HOME ZOPE_HOME PATH CLIENT_HOME
+
+exec python $ZOPE_HOME/z2.py            \
+       -u      zope                    \
+       -z      /usr/lib/zope           \
+       -Z      /var/run/zwatchdog.pid  \
+       -w      8080                    \
+       -f      8021                    \
+       -m      ''                      \
+       -l      /var/log/zope           \
+       >>      /var/log/zope 2>&1      \
+       &
diff --git a/Zope.init b/Zope.init
new file mode 100644 (file)
index 0000000..6792ae2
--- /dev/null
+++ b/Zope.init
@@ -0,0 +1,66 @@
+#!/bin/sh
+#
+# zope          Start/Stop the Zope web-application server.
+#
+# chkconfig: 2345 72 72
+# description: zope is a web server specifically for handling \
+#              HTTP requests to the Zope web-application service.
+# probe: true
+
+# Source function library.
+. /etc/rc.d/init.d/functions
+
+ZOPE_HOME=/usr/lib/zope
+INSTANCE_HOME=/var/lib/zope
+INSTANCE_NAME=`basename ${INSTANCE_HOME}`
+
+RETVAL=0
+
+# See how we were called.
+case "$1" in
+    start)
+       if [ -f /var/lock/subsys/zope ]; then
+               msg_Already_Running Zope
+       else    
+               msg_starting Zope
+               busy
+               daemon zope-zserver
+               RETVAL=$?;
+               sleep 5
+               [ $RETVAL -eq 0 ] && touch /var/lock/subsys/zope
+       fi
+       ;;
+  stop)
+        if [ -f /var/lock/subsys/zope ]; then
+                msg_stopping Zope
+                kill `cat ${INSTANCE_HOME}/Z2.pid`
+               sleep 1
+               deltext
+               ok
+                rm -f /var/lock/subsys/zope >/dev/null 2>&1
+        else
+                msg_not_running Zope
+                exit 1
+        fi
+       ;;
+  status)
+       if ps -p `cat ${INSTANCE_HOME}/Z2.pid | awk '{print $2}'` >/dev/null; then
+           RETVAL=$?
+           echo "Zope (pid `cat ${INSTANCE_HOME}/Z2.pid`) is running"
+       else     
+           msg_not_running Zope
+           RETVAL=1
+       fi
+    
+       ;;
+  restart)
+       $0 stop
+       $0 start
+       ;;
+  *)
+       msg_Usage "$0 {start|stop|status|restart}"
+       exit 1
+       ;;
+esac
+
+exit $RETVAL
This page took 0.038702 seconds and 4 git commands to generate.