root/10kz/start.sh

Revision 41, 0.6 kB (checked in by jm3, 2 years ago)

refined the start script and added a configure file to be populated with correct paths on install

  • Property svn:executable set to *
  • Property svn:keywords set to Id
Line 
1 #!/bin/sh
2 # local webserver startup script
3 # $Id$
4
5 root=/usr/local/10kz
6
7 process=`ps aux | grep [m]ini | awk '{print $2}'`
8 if [ -n "$process" ]
9 then
10         echo -n "restarting server: "
11         kill -9 $process
12 else
13         echo -n "starting server: "
14 fi
15
16 if [ -d $root ]
17 then
18         $root/webserver/mini_httpd/mini_httpd -p 6667 -d $root/shell/ -c \*.jm3
19         sleep 1
20         lynx=`which lynx`
21         if [ -f "$lynx" ]
22         then
23                 lynx --dump http://localhost:6667/test-cgi.jm3
24         fi
25
26         echo done.
27         exit 0
28
29 else
30         echo "Failed; the directory where i expected to find the server ($root) doesn't exist."
31         exit 1
32 fi
33
Note: See TracBrowser for help on using the browser.