JT Moree wrote:
I created a run_fork.  I had to change the location of softlimit on my
system so I included it as a variable.  I guess I could create a
config/SOFTLIMIT file since everything else is in a file . . .

#!/bin/sh
# run_fork

# get dirname of executable so we can cd into it in case there
# are multiple versions of qpsmtpd installed and running
WHERE=`dirname $0`
cd $WHERE || exit 1

SOFTLIMIT=/usr/sbin/softlimit #in case yours is not here change this

if [ -f "config/PORTS" ] ; then
  for P in `cat config/PORTS` ; do              #for each port found
    if [ -z "`echo $P | grep '^\s*#'`" ] ; then #strip out comments
      PORTS="$PORTS --port $P"
    fi
  done
fi
if [ -f "config/IP" ] ; then
  IP=`head -1 config/IP`        #only uses first line in file
fi
exec \
     $SOFTLIMIT -m 30000000 \
     /usr/bin/perl -T -Ilib \
     ./qpsmtpd-forkserver \
     --listen-address $IP \
     --limit-connections 40 \
     $PORTS


Ah, I thought you were talking about implementing it as a plugin, rather than as part of a run script that would have to be duplicated for every other run script. Now that I read through the code, I see that config/IP is only used by run scripts. Would anyone see any value in having it be part of the daemon (qpsmtpd-forkserver, qpsmtpd-prefork, etc)?

Reply via email to