freebsd-ports/net-mgmt/argus-monitor/files/pkg-install.in
Olli Hauer 8003f3f40e - rewrite for options NG framework
- /USE_APACHE/USE_APACHE_RUN/
- make usage of ETCDIR, WWWDIR instead PREFIX/(etc|www)/PORTNAME
- add pkg-install script to adjust directory file mode,
  else they differ when installed by package
- use @dirrmtry to preserve existing stats ...
- bump PORTREVISION

PR:             171475
Submitted by:   ohauer
Approved by:    (old) maintainer timeout (port was moved today to ports@)
2012-10-07 18:44:44 +00:00

22 lines
723 B
Bash

#!/bin/sh
#
# $FreeBSD$
ETCDIR=%%ETCDIR%%
WWWDIR=%%WWWDIR%%
if [ "$2" = "POST-INSTALL" ]; then
[ ! -d ${ETCDIR}/gcache ] && mkdir ${ETCDIR}/gcache
[ ! -d ${ETCDIR}/gdata ] && mkdir ${ETCDIR}/gdata
[ ! -d ${ETCDIR}/html ] && mkdir ${ETCDIR}/html
[ ! -d ${ETCDIR}/locale ] && mkdir ${ETCDIR}/locale
[ ! -d ${ETCDIR}/perl ] && mkdir ${ETCDIR}/perl
chmod a+rwx ${ETCDIR}/gcache ${ETCDIR}/gdata ${ETCDIR}/perl
chmod a+rx ${ETCDIR}/locale
chmod a+r ${ETCDIR}/html
chmod 755 ${WWWDIR} ${WWWDIR}/docroot ${WWWDIR}/docroot/img \
${WWWDIR}/docroot/sound ${ETCDIR} ${ETCDIR}/notify
chmod 644 ${WWWDIR}/docroot/argus.* ${WWWDIR}/docroot/img/*.gif \
${WWWDIR}/docroot/sound/*.wav ${ETCDIR}/notno ${ETCDIR}/log
fi