mirror of
https://git.FreeBSD.org/ports.git
synced 2025-01-03 06:04:53 +00:00
487ae359bd
PR: ports/152479 Submitted by: Josh Paetzel <jpaetzel@FreeBSD.org> Approved by: Denis Pokataev <catone@cpan.org> (maintainer)
32 lines
574 B
Bash
32 lines
574 B
Bash
#! /bin/sh
|
|
# $FreeBSD#
|
|
|
|
PATH=/bin:/usr/bin:/usr/sbin
|
|
|
|
MKDIR="%%MKDIR%%"
|
|
CHOWN="%%CHOWN%%"
|
|
CHMOD="%%CHMOD%%"
|
|
|
|
DBDIR="%%POOTLEDBDIR%%"
|
|
LOGDIR="%%POOTLELOGDIR%%"
|
|
RUNDIR="%%POOTLERUNDIR%%"
|
|
|
|
UID="%%POOTLEUSER%%"
|
|
GID="%%POOTLEGROUP%%"
|
|
|
|
case $2 in
|
|
|
|
POST-INSTALL)
|
|
for DIR in ${LOGDIR} ${DBDIR} ${RUNDIR}; do
|
|
if [ ! -d ${DIR} ]; then
|
|
echo "===> Creating directory ${DIR}"
|
|
${MKDIR} ${DIR}
|
|
echo "===> Changing ownership of ${DIR}"
|
|
${CHOWN} -R ${UID}:${GID} ${DIR}
|
|
echo "===> Changing permissions of ${DIR}"
|
|
${CHMOD} -R 770 ${DIR}
|
|
fi
|
|
done
|
|
;;
|
|
esac
|