forked from Lainports/freebsd-ports
36 lines
612 B
Bash
36 lines
612 B
Bash
#!/bin/sh
|
|
#
|
|
# $FreeBSD$
|
|
#
|
|
|
|
PATH=/usr/sbin:/usr/bin:/bin ; export PATH
|
|
|
|
WWWDIR=%%WWWDIR%%
|
|
SUPHP_ENABLED=%%SUPHP_ENABLED%%
|
|
CFG_FILE=%%CFG_FILE%%
|
|
pma_usr=%%PMA_USR%%
|
|
pma_grp=%%PMA_GRP%%
|
|
|
|
case $2 in
|
|
|
|
POST-INSTALL)
|
|
|
|
# If suPHP is in use, change ownership of the phpMyAdm
|
|
# directory
|
|
|
|
if [ ! -z ${SUPHP_ENABLED} ] ; then
|
|
echo "===> Adjusting file ownership in $WWWDIR"
|
|
chown -R $pma_usr:$pma_grp $WWWDIR || exit 1
|
|
fi
|
|
|
|
# Install the config file if it doesn't exist
|
|
|
|
if [ ! -f ${CFG_FILE} ] ; then
|
|
cp -p ${CFG_FILE}.sample ${CFG_FILE}
|
|
fi
|
|
;;
|
|
esac
|
|
|
|
#
|
|
# That's All Folks!
|
|
#
|