#!/bin/sh
## *** THIS IS TEMPLATE OF run SCRIPT                     ***
## *** DO NOT USE THIS FILE. USE run SCRIPT AFTER DO make ***
##
PATH=/bin:/sbin:/usr/bin:/usr/ucb:/usr/local/bin:_ABM_:_UCSPI_TCP_
export PATH
QUSER=${QUSER:-abm}
if [ -x /usr/xpg4/bin/id ]; then
  ID=/usr/xpg4/bin/id
else
  ID=id
fi

UID=`$ID -u $QUSER`
GID=`$ID -g $QUSER`
if [ `whoami` = "root" ]; then
  DROPPRIV="-u$UID -g$GID"
fi
[ $DEBUG ] && echo uid=$UID GID=$GID $DROPPRIV
QPORT=9999

exec env - PATH=$PATH \
tcpserver -vR -c30 $DROPPRIV -xq.cdb 0 $QPORT ./q 2>&1
