opengrok.sh revision 115
115N/A#! /bin/ksh
115N/A# CDDL HEADER START
115N/A#
115N/A# The contents of this file are subject to the terms of the
115N/A# Common Development and Distribution License (the "License").
115N/A# You may not use this file except in compliance with the License.
115N/A#
115N/A# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
115N/A# or http://www.opensolaris.org/os/licensing.
115N/A# See the License for the specific language governing permissions
115N/A# and limitations under the License.
115N/A#
115N/A# When distributing Covered Code, include this CDDL HEADER in each
115N/A# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
115N/A# If applicable, add the following below this CDDL HEADER, with the
115N/A# fields enclosed by brackets "[]" replaced with your own identifying
115N/A# information: Portions Copyright [yyyy] [name of copyright owner]
115N/A#
115N/A# CDDL HEADER END
115N/A
115N/A# Copyright 2007 Sun Microsystems, Inc. All rights reserved.
115N/A# Use is subject to license terms.
115N/A
115N/A
115N/A# The root direction of this opengrok installation
115N/AROOT=/opengrok; export ROOT
115N/A# How often should the source be updated (in seconds)
115N/ASLEEPTIME=1800; export SLEEPTIME
115N/A
115N/A# The Java version to use
115N/AJAVA_HOME=/usr/jdk/latest; export JAVA_HOME
115N/A
115N/A# The path needed
115N/APATH=/usr/bin; export PATH
115N/A
115N/A# The name of the various SCM tools to use
115N/A# CVS=/usr/bin/cvs; export CVS
115N/A# SUBVERSION=/usr/bin/svn; export SUBVERSION
115N/A# MERCURIAL=/usr/bin/hg; export MERCURIAL
115N/A
115N/A# The name of the web servers that should be notified with the information
115N/A# of the active configuration to use. Specify them with hostname:port and
115N/A# separate multiple hosts by space.
115N/A# WEBSERVERS="server1:2424 server2:2424"
115N/A# WEBSERVERS="localhost:2424"
115N/A
115N/A# The email address to send an email if the source update fails, or a fatal
115N/A# error occurs while the index database is beeing updated.
115N/AADMINISTRATOR=root@localhost; export ADMINISTRATOR
115N/A
115N/A# The current version of the Mercurial log parser expects C date format.
115N/ALC_ALL=C; export LC_ALL
115N/A
115N/A# Additional directories to look for libraries in.
115N/A# (Subversions java binding etc)
115N/ALD_LIBRARY_PATH=/opt/csw/lib/svn; export LD_LIBRARY_PATH
115N/A
115N/Acase "$1" in
115N/A start)
115N/A su opengrok -c "${ROOT}/smf/indexer.sh" &
115N/A ;;
115N/A
115N/A stop)
115N/A pkill -u opengrok -x indexer.sh
115N/A ;;
115N/A
115N/A *)
115N/A echo "Usage: $0 {start|stop}"
115N/A exit 1
115N/A ;;
115N/Aesac
115N/A
115N/Aexit 0