Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 2 Jan 2005 03:47:37 -0800
From:      "Leonard Chung" <leonard@chung.yikes.com>
To:        <questions@freebsd.org>
Subject:   Setting IMAPd MAILDIR?
Message-ID:  <21DD5D42C3DAC64C91CF8DB890CA57EB014852@emachine.my.domain>

next in thread | raw e-mail | index | archive | help
Hi there,

=20

I recently upgraded courier-imap using portupgrade, and I've noticed
that it no longer uses the proper maildir directory (./Maildir), but
rather just the user home directory.

=20

This seems to have to do with the change of courier-imap to rc.subr
style scripts. It uses a variable called MAILDIRPATH which isn't defined
anywhere that I can find:

=20

                /usr/local/libexec/courier-imap/couriertcpd
-address=3D$ADDRESS \

                        =
-stderrlogger=3D${exec_prefix}/sbin/courierlogger
\

                        -stderrloggername=3Dimapd \

                        -maxprocs=3D$MAXDAEMONS -maxperip=3D$MAXPERIP \

                        -pid=3D$PIDFILE $TCPDOPTS \

                        $PORT ${exec_prefix}/sbin/imaplogin
$LIBAUTHMODULES \

                                ${exec_prefix}/bin/imapd ${MAILDIRPATH}"

=20

If I delete ${MAILDIRPATH} and replace it with "./Maildir", then
everything works fine. However, I imagine there is a better (i.e.
recommended) place for me to put this information. This is a machine
running 4.10REL.

=20

Can somebody tell me where MAILDIRPATH is supposed to be defined within
this new rc.subr scheme and also if anybody has any idea why the rc
script uses a variable which is undefined?

=20

Thanks!

=20

Leonard

=20

leonard@chung:/usr/local/libexec/courier-imap# more imapd.rc=20

#! /bin/sh

# $Id: imapd.rc.in,v 1.26 2004/04/18 15:54:38 mrsam Exp $

#

# Copyright 1998 - 2002 Double Precision, Inc.

# See COPYING for distribution information.

=20

=20

prefix=3D/usr/local

exec_prefix=3D/usr/local

bindir=3D${exec_prefix}/bin

libexecdir=3D/usr/local/libexec/courier-imap

=20

if test ! -f /usr/local/etc/courier-imap/imapd

then

        echo "/usr/local/etc/courier-imap/imapd does not exist, forgot
make install-configure?"

        exit 1

fi

=20

if test ! -f /usr/local/etc/courier-imap/imapd-ssl

then

        echo "/usr/local/etc/courier-imap/imapd-ssl does not exist,
forgot make install-configure?"

        exit 1

fi

=20

TLS_CACHEFILE=3D""

. /usr/local/etc/courier-imap/imapd-ssl

. /usr/local/etc/courier-imap/imapd

=20

case $1 in

start)

        LIBAUTHMODULES=3D""

        for f in `echo $AUTHMODULES`

        do

                LIBAUTHMODULES=3D"$LIBAUTHMODULES
/usr/local/libexec/courier-imap/authlib/$f"

        done

=20

        if test -x ${libexecdir}/authlib/authdaemond

        then

                /usr/bin/env - DEBUG_LOGIN=3D"$DEBUG_LOGIN"
${libexecdir}/authlib/authdaemond start

        fi

=20

        if test "$TLS_CACHEFILE" !=3D ""

        then

                rm -f $TLS_CACHEFILE

        fi

=20

        ulimit -v $IMAP_ULIMITD

        /usr/bin/env - /bin/sh -c " set -a ;

                        prefix=3D/usr/local ;

                        exec_prefix=3D/usr/local ;

                        bindir=3D${exec_prefix}/bin ;

                        libexecdir=3D/usr/local/libexec/courier-imap ;

                                . /usr/local/etc/courier-imap/imapd ; \

                                . /usr/local/etc/courier-imap/imapd-ssl
; \

                IMAP_STARTTLS=3D$IMAPDSTARTTLS ; export IMAP_STARTTLS ; =
\

                TLS_PROTOCOL=3D$TLS_STARTTLS_PROTOCOL ; \

                /usr/local/libexec/courier-imap/couriertcpd
-address=3D$ADDRESS \

                        =
-stderrlogger=3D${exec_prefix}/sbin/courierlogger
\

                        -stderrloggername=3Dimapd \

                        -maxprocs=3D$MAXDAEMONS -maxperip=3D$MAXPERIP \

                        -pid=3D$PIDFILE $TCPDOPTS \

                        $PORT ${exec_prefix}/sbin/imaplogin
$LIBAUTHMODULES \

                                ${exec_prefix}/bin/imapd ${MAILDIRPATH}"

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^

        ;;

stop)

        /usr/local/libexec/courier-imap/couriertcpd -pid=3D$PIDFILE =
-stop

        if test -x ${libexecdir}/authlib/authdaemond

        then

                ${libexecdir}/authlib/authdaemond stop

        fi

        ;;

esac

exit 0



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?21DD5D42C3DAC64C91CF8DB890CA57EB014852>