2004-01-11 17:45:51 +01:00
|
|
|
# $NetBSD: INSTALL,v 1.3 2004/01/11 16:45:51 cjep Exp $
|
2002-06-16 13:34:26 +02:00
|
|
|
|
2004-01-11 17:45:51 +01:00
|
|
|
LEAFNODE_CONFDIR=@LEAFNODE_CONFDIR@
|
|
|
|
LEAFNODE_SPOOL=@LEAFNODE_SPOOL@
|
|
|
|
LEAFNODE_LOCKDIR=@LEAFNODE_LOCKDIR@
|
|
|
|
LEAFNODE_HOME=@LEAFNODE_HOME@
|
2002-06-16 13:34:26 +02:00
|
|
|
|
2004-01-11 17:45:51 +01:00
|
|
|
if [ "${STAGE}" = "POST-INSTALL" ]; then
|
2002-06-16 13:34:26 +02:00
|
|
|
|
2004-01-11 17:45:51 +01:00
|
|
|
mkdir -p ${LEAFNODE_CONFDIR}
|
|
|
|
if [ ! -f ${LEAFNODE_CONFDIR}/config ]; then
|
|
|
|
cp ${PREFIX}/share/examples/leafnode/config.example \
|
|
|
|
${LEAFNODE_CONFDIR}/config
|
|
|
|
chmod u+w ${LEAFNODE_CONFDIR}/config
|
|
|
|
fi
|
2002-06-16 13:34:26 +02:00
|
|
|
|
2004-01-11 17:45:51 +01:00
|
|
|
echo "Creating leafnode spool directories..."
|
2002-06-16 13:34:26 +02:00
|
|
|
|
2004-01-11 17:45:51 +01:00
|
|
|
SPOOL_DIRS="leaf.node failed.postings interesting.groups out.going message.id"
|
2002-06-16 13:34:26 +02:00
|
|
|
|
2004-01-11 17:45:51 +01:00
|
|
|
mkdir -p ${LEAFNODE_SPOOL}
|
|
|
|
chown news:news ${LEAFNODE_SPOOL}
|
|
|
|
chmod 2775 ${LEAFNODE_SPOOL}
|
2002-06-16 13:34:26 +02:00
|
|
|
|
2004-01-11 17:45:51 +01:00
|
|
|
for D in $SPOOL_DIRS; do
|
|
|
|
mkdir -p ${LEAFNODE_SPOOL}/$D;
|
|
|
|
chown news:news ${LEAFNODE_SPOOL}/$D
|
|
|
|
chmod 2775 ${LEAFNODE_SPOOL}/$D
|
|
|
|
done
|
2002-06-16 13:34:26 +02:00
|
|
|
|
2004-01-11 17:45:51 +01:00
|
|
|
mkdir -p ${LEAFNODE_LOCKDIR}
|
|
|
|
chown news:news ${LEAFNODE_LOCKDIR}
|
|
|
|
chmod 2775 ${LEAFNODE_LOCKDIR}
|
|
|
|
|
|
|
|
# Make directories (a la quickmkdir)
|
|
|
|
for a in 0 1 2 3 4 5 6 7 8 9; do
|
|
|
|
for b in 0 1 2 3 4 5 6 7 8 9; do
|
|
|
|
for c in 0 1 2 3 4 5 6 7 8 9; do
|
|
|
|
mkdir -m 2775 -p ${LEAFNODE_SPOOL}/message.id/$a$b$c
|
|
|
|
chown news:news ${LEAFNODE_SPOOL}/message.id/$a$b$c
|
|
|
|
done
|
2002-06-16 13:34:26 +02:00
|
|
|
done
|
|
|
|
done
|
|
|
|
|
2004-01-11 17:45:51 +01:00
|
|
|
mkdir -p ${LEAFNODE_HOME}
|
|
|
|
chown news:news ${LEAFNODE_HOME}
|
|
|
|
fi
|