aboutsummaryrefslogtreecommitdiff
path: root/www/aolserver/files/pkg-install.in
diff options
context:
space:
mode:
authorGabor Kovesdan <gabor@FreeBSD.org>2007-02-02 14:46:50 +0000
committerGabor Kovesdan <gabor@FreeBSD.org>2007-02-02 14:46:50 +0000
commitd7987b732daa38487453f0e06ba8b8c4d59f21bd (patch)
treee910b7f625214b5ad9fe5358806bafd6d4c6e0d8 /www/aolserver/files/pkg-install.in
parentc9914d157b4312f0b98f0cdd7ac6bc098a863cc0 (diff)
downloadports-d7987b732daa38487453f0e06ba8b8c4d59f21bd.tar.gz
ports-d7987b732daa38487453f0e06ba8b8c4d59f21bd.zip
Notes
Diffstat (limited to 'www/aolserver/files/pkg-install.in')
-rw-r--r--www/aolserver/files/pkg-install.in33
1 files changed, 8 insertions, 25 deletions
diff --git a/www/aolserver/files/pkg-install.in b/www/aolserver/files/pkg-install.in
index f04e99563569..901d0c348501 100644
--- a/www/aolserver/files/pkg-install.in
+++ b/www/aolserver/files/pkg-install.in
@@ -3,35 +3,19 @@
PATH=/bin:/usr/sbin:/usr/bin
EXAMPLESDIR=%%EXAMPLESDIR%%
AOLSERVERBASE=%%AOLSERVERBASE%%
+AOLSERVERUSER=%%AOLSERVERUSER%%
+AOLSERVERGROUP=%%AOLSERVERGROUP%%
post-install() {
echo "Running post-install script"
echo "Setting file permissions"
- chown nobody:nogroup ${AOLSERVERBASE}/servers/server1/modules/nslog
- chown nobody:nogroup ${AOLSERVERBASE}/log
+ mkdir -p ${AOLSERVERBASE}/servers/server1/pages
+ mkdir -p ${AOLSERVERBASE}/servers/server1/modules/nslog
+ mkdir -p ${AOLSERVERBASE}/log
+ echo "Welcome. You have made it. Aolserver has started." >> ${AOLSERVERBASE}/servers/server1/pages/index.html
+ chown ${AOLSERVERUSER}:${AOLSERVERGROUP} ${AOLSERVERBASE}/servers/server1/modules/nslog
+ chown ${AOLSERVERUSER}:${AOLSERVERGROUP} ${AOLSERVERBASE}/log
chmod 755 ${AOLSERVERBASE}
- chmod 755 ${EXAMPLESDIR}/aolserver.sh.sample
-
- echo "Checking Aolserver processes before (re)start"
- pid1=`ps -ax | grep sample-config | grep -v grep| awk -F' ' '{print $1}'`;
- if test "$pid1" = "" ; then
- echo ""
- else
- echo "Killing sample-config pid"
- kill $pid1;
- fi
-
- pid2=`ps -ax | grep nsd | grep -v grep| awk -F' ' '{print $1}'`;
- if test "$pid2" = "" ; then
- echo "Good. No running Aolserver process.";
- else
- echo "Warning: at least one non-standard Aolserver process is running..."
- echo "We are still starting Aolserver, but it may not be able to listen on the same address:port"
- echo "FYI: killall -9 nsd stops all processes. Or change the IP-address in config.tcl, then restart."
- fi
-
- echo "Starting aolserver: ${AOLSERVERBASE}/bin/nsd -t ${AOLSERVERBASE}/sample-config.tcl -u nobody -g nogroup"
- ${AOLSERVERBASE}/bin/nsd -t ${AOLSERVERBASE}/sample-config.tcl -u nobody -g nogroup
}
case $2 in
@@ -40,7 +24,6 @@ POST-INSTALL)
post-install
;;
*)
- echo "unknown pkg-install option"
;;
esac