#! /bin/sh
#
# Copyright 2015 Double Precision, Inc.  See COPYING for
# distribution information.

prefix="/usr/local"
exec_prefix="/usr/local"
sysconfdir="/etc/courier"
localstatedir="/var"
bindir="/usr/local/bin"
sbindir="/usr/local/sbin"
libexecdir="/usr/local/libexec"

. ${sysconfdir}/imapd
. ${sysconfdir}/imapd-ssl

umask 022
${libexecdir}/makedat \
	-src=${IMAPACCESSFILE} \
	-file=${IMAPACCESSFILE}.dat \
	-tmp=${IMAPACCESSFILE}.tmp -cidr || exit 1

${libexecdir}/couriertcpd -pid=$PIDFILE -restart
${libexecdir}/couriertcpd -pid=$SSLPIDFILE -restart
