Roxen.git / server / start

version» Context lines:

Roxen.git/server/start:1:   #!/bin/sh   # - # $Id: start,v 1.146 2001/01/31 04:26:18 per Exp $ + # $Id: start,v 1.147 2001/01/31 07:32:36 per Exp $      ### If --silent-start is given as the first argument,   ### nothing will be printed to stdout by the script.      if [ "x$1" = "x--silent-start" ] ; then    SILENT_START="y"    shift   fi      check_owner() {
Roxen.git/server/start:115:    dp "Removing old precompiled files ($1)"    # This really cannot be done from here anymore -- pass on an option    # to roxenloader instead.    pass="$pass --remove-dumped"   }      ## Parse all arguments.   ## GNU-style, long options only, except for -D, simply passed on.   ARGS=""    + setup_for_tests() { +  DEFINES="-DRUN_SELF_TEST $DEFINES" +  # Kill roxen mysql if it's running... +  if [ -f ${VARDIR}test_config/_mysql/mysql_pid ] ; then +  kill `cat ${VARDIR}test_config/_mysql/mysql_pid` +  fi +  rm -rf "$VARDIR""test_config"* +  cp -R etc/roxen_test/test_config $VARDIR +  cp etc/roxen_test/filesystem/test_rxml_package rxml_packages/test_rxml_package +  DIR="$VARDIR""test_config" +  once=1 +  remove_dumped=1 + } +    parse_args() {    while [ ! c"$1" = "c" ] ; do    case $1 in    -D*)    DEFINES="$DEFINES $1"    ;;    -l*)    ARGS="$ARGS $1"    ;;    --truss)
Roxen.git/server/start:226:    '--version')    if [ -f base_server/roxen.pike ]; then    echo "Roxen WebServer `roxen_version`"    exit 0    else    echo 'base_server/roxen.pike not found!'    exit 1    fi    ;;    '--self-test') -  DEFINES="-DRUN_SELF_TEST $DEFINES" -  # Kill roxen mysql if it's running... -  if [ -f ${VARDIR}test_config/_mysql/mysql_pid ] ; then -  kill `cat ${VARDIR}test_config/_mysql/mysql_pid` -  fi -  rm -rf "$VARDIR""test_config"* -  cp -R etc/roxen_test/test_config $VARDIR -  cp etc/roxen_test/filesystem/test_rxml_package rxml_packages/test_rxml_package -  DIR="$VARDIR""test_config" -  once=1 -  remove_dumped=1 +  setup_for_tests    ;; -  +  '--self-test-quiet') +  debug=-1 +  SILENT_START=y +  do_pipe="| grep ' |'" +  setup_for_tests +  ;; +  '--self-test-verbose') +  pass="$pass --tests-verbose=1" +  setup_for_tests +  ;;    '--help'|'-?')    sed -e "s/\\.B/`tput 'bold' 2>/dev/null`/g" -e "s/B\\./`tput 'sgr0' 2>/dev/null`/g" << EOF   .BThis command will start the Roxen WebServerB..      The environment variable .BROXEN_ARGSB. can be used to specify   the default arguments.       .BArguments:B.       .B--versionB.: Output version information.
Roxen.git/server/start:292:    a directory basis. This information is    not saved on permanent storage, it is only    available until the next server restart    This will enable a new 'action' in the    administration interface       .B--with-file-profileB.: Like .B--with-profileB., but save information    for each and every file.       .B--self-testB.: Runs a testsuite. -  WARNING: This will kill any running -  roxen_mysql processes +  .B--self-test-verboseB.: Runs a testsuite, report all tests. +  .B--self-test-quiet.: Runs a testsuite, only report errors.       .B--onceB.: Run the server only once, in the foreground.    This is very useful when debugging.       .B--gdbB.: Run the server in gdb. Implies .B--onceB..       .B--programB.: Start a different program with the roxen    Pike. As an example,    .B./start --program bin/install.pikeB. will    start the installation program normally
Roxen.git/server/start:555:    if [ $verbose -gt 1 -o -z "$once" ] ; then    dp "Executing $pike $args $@"|sed -e "s!`pwd`!.!g"    else    dp "Using the '$pike' pike binary"|sed -e "s!`pwd`!.!g"    fi    fi       trap signal_exit 2 15    trap "" 1    if [ "x$once" = "x" ]; then -  $pike $args "$@" 2>>$LOGDIR/debug/$FILES.1 1>&2 & +  $pike $args "$@" 2>>$LOGDIR/debug/$FILES.1 1>&2    ROXEN_PID=$!    dp "Roxen WebServer server pid $ROXEN_PID."    wait $! 2>/dev/null 1>&2    exitcode="$?"    ROXEN_PID=""    else -  +  if [ "x$do_pipe" = "x" ] ; then    $pike $args "$@" 2>&1 -  +  else +  eval "$pike $args "$@" 2>&1 $do_pipe"    fi -  +  fi    else    echo >.gdbinit handle SIGPIPE nostop noprint pass    echo >>.gdbinit handle SIGUSR1 nostop noprint pass    echo >>.gdbinit handle SIGUSR2 nostop noprint pass    echo >>.gdbinit handle SIGLWP nostop noprint pass    firstline=`head -1 "$pike" 2>/dev/null`    if expr "x$firstline" : 'x#! */.*' >/dev/null; then    # Looks like a script. gdb will not grok it, so we try passing    # --gdb to it instead (which works in the special case of the    # bin/pike script that is built by the top level Makefile in the