Commit bee54e46 authored by Leigh B. Stoller's avatar Leigh B. Stoller
Browse files

Apply path changes to ron scripts.

parent c4d01afe
......@@ -4,14 +4,15 @@
# Copyright (c) 2000-2002 University of Utah and the Flux Group.
# All rights reserved.
#
. /etc/emulab/paths.sh
#
# Fire up a cvsup each time we boot.
#
case "$1" in
start)
if [ -f /usr/local/etc/emulab/runcvsup.sh ]; then
/usr/local/etc/emulab/runcvsup.sh && echo -n ' cvsup'
if [ -f $BINDIR/runcvsup.sh ]; then
$BINDIR/runcvsup.sh && echo -n ' cvsup'
fi
;;
stop)
......
......@@ -4,23 +4,31 @@
# Copyright (c) 2000-2002 University of Utah and the Flux Group.
# All rights reserved.
#
. /etc/emulab/paths.sh
#
# Boottime initialization.
#
case "$1" in
start)
if [ -f /usr/local/etc/emulab/emulabctl ]; then
/usr/local/etc/emulab/emulabctl start
if [ -f $BINDIR/emulabctl ]; then
$BINDIR/emulabctl start
fi
;;
stop)
if [ -f /usr/local/etc/emulab/emulabctl ]; then
/usr/local/etc/emulab/emulabctl stop
if [ -f $BINDIR/emulabctl ]; then
$BINDIR/emulabctl stop
fi
;;
restart)
if [ -f $BINDIR/emulabctl ]; then
$BINDIR/emulabctl stop
sleep 10
$BINDIR/emulabctl start
fi
;;
*)
echo "Usage: `basename $0` {start|stop}" >&2
echo "Usage: `basename $0` {start|stop|restart}" >&2
;;
esac
......
......@@ -4,20 +4,21 @@
# Copyright (c) 2000-2002 University of Utah and the Flux Group.
# All rights reserved.
#
. /etc/emulab/paths.sh
#
# Boottime initialization.
#
case "$1" in
start)
/usr/local/etc/emulab/watchdog > /dev/null 2>&1 && echo -n ' Emulab'
$BINDIR/watchdog > /dev/null 2>&1 && echo -n ' Emulab'
#
# Do not start the mini server on RON nodes yet.
#
if [ -x /usr/local/etc/emulab/webserver.pl -a -e /etc/emulab.pkey ]
if [ -x $BINDIR/webserver.pl -a -e /etc/emulab.pkey ]
then
/usr/local/etc/emulab/webserver.pl && echo -n ' Webserver'
$BINDIR/webserver.pl && echo -n ' Webserver'
fi
;;
stop)
......
......@@ -17,7 +17,7 @@ sub usage()
{
die("Usage: webserver.pl\n");
}
my $logname = "/var/tmp/webserver.log";
my $logname = "/var/emulab/logs/webserver.log";
my $pidfile = "/var/run/webserver.pid";
my $webpage = "http://www.emulab.net/widearea_redirect.php";
my $IP;
......@@ -25,7 +25,7 @@ my $IP;
#
# Untaint path
#
$ENV{'PATH'} = '/bin:/sbin:/usr/bin:/usr/local/bin:/usr/local/etc/emulab';
$ENV{'PATH'} = '/bin:/sbin:/usr/bin:/usr/local/bin';
delete @ENV{'IFS', 'CDPATH', 'ENV', 'BASH_ENV'};
#
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment