indexer.sh revision 2e3888b9e322264fa8a5bd5c8b52df231f2eeded
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye# CDDL HEADER START
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye# The contents of this file are subject to the terms of the
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye# Common Development and Distribution License (the "License").
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye# You may not use this file except in compliance with the License.
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye# See LICENSE.txt included in this distribution for the specific
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye# language governing permissions and limitations under the License.
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye# When distributing Covered Code, include this CDDL HEADER in each
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye# file and include the License file at LICENSE.txt.
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye# If applicable, add the following below this CDDL HEADER, with the
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye# fields enclosed by brackets "[]" replaced with your own identifying
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye# information: Portions Copyright [yyyy] [name of copyright owner]
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye# CDDL HEADER END
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye# Copyright 2007 Sun Microsystems, Inc. All rights reserved.
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye# Use is subject to license terms.
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye mailx -s "{OpenGrok update failed" ${ADMINISTRATOR} < ${output}
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye SRC_ROOT=${ROOT}/stage${stage}/source; export SRC_ROOT
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye DATA_ROOT=${ROOT}/stage${stage}/data; export DATA_ROOT
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye # update source code
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye # (re)generate index database
66d6362ed4101c93b6eaa749598bfb3cd030be3fTrond Norbye # You may want to add something like the following command
66d6362ed4101c93b6eaa749598bfb3cd030be3fTrond Norbye # to automatically generate projects for each subdirectory in the
66d6362ed4101c93b6eaa749598bfb3cd030be3fTrond Norbye # SRC_ROOT directory. The -p options let you specify the project
66d6362ed4101c93b6eaa749598bfb3cd030be3fTrond Norbye # that should be selected by default (note that the parameter here
66d6362ed4101c93b6eaa749598bfb3cd030be3fTrond Norbye # is the path to the project)
2e3888b9e322264fa8a5bd5c8b52df231f2eededTrond Norbye # ADD_PROJECTS="-S -P -p /onnv-gate -W ${DATA_ROOT}/../configuration.xml"
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye ${JAVA_HOME}/bin/java -Xmx1524m -jar ${PROGDIR}/opengrok.jar \
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye # notify web-servers
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye # Use rsync to populate the files out to the web server
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye # rsync -a configuration.xml stage${stage} \
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye # /net/`echo $f|cut -f1 -d:`/opengrok/
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye # if [ $? -eq 0 ]
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye # Tell the web server to use the new configuration
96c1ae30d032621b47c4ac375b151ddaef5f1507Trond Norbye # update running configuration