#!/bin/sh # Update-WWW v1.3 (c) 25.1.94 by Andreas Ley (u) 29.8.97 # Parses the configuration and calls all the necessary update scripts # Maximum sub-script time to run TimeOut=3600 # Defaults ServerRoot=/usr/local/etc/httpd CacheRoot=${ServerRoot}/cache DirectoryIndex=index.html LogFileDateExt=%Y%m%d SuffixDE=.de SuffixEN=.en Domain=rz.uni-karlsruhe.de MailServer=mailhost.${Domain} NewsServer=news.${Domain} HostName=`hostname`.${Domain} # Read configuration file eval `awk '$1=="ServerRoot"||$1=="CacheRoot"||$1=="UserDir"||$1=="HostName"||$1=="PidFile"||$1=="AccessLog"||$1=="ProxyAccessLog"||$1=="CacheAccessLog"||$1=="ErrorLog"||$1=="LogFileDateExt"{print$1"="$2}' ${ServerRoot}/config/httpd.conf ${ServerRoot}/conf/srm.conf` # System configuration values needed in scripts PATH=${ServerRoot}/bin:/usr/machine/bin:/bin:/usr/bin:/usr/segment/bin if echo "\c" | grep "c" >/dev/null; then echon='-n' echoc='' else echon='' echoc='\c' fi DocumentRoot=${ServerRoot}/htdocs DateExt=`date +${LogFileDateExt}` export ServerRoot DocumentRoot CacheRoot UserDir DirectoryIndex HostName PidFile MailServer NewsServer Domain SuffixDE SuffixEN LogFileDateExt export PATH echon echoc DateExt TimeOut # Call all subroutines cd ${ServerRoot}/bin umask 022 prefix=`basename $0` if test $# -gt 0; then for facility do script=${prefix}-${facility} test -x ${script} && alarm ${TimeOut} ./${script} done else for script in ${prefix}-*; do test -x ${script} && alarm ${TimeOut} ./${script} done fi exit 0