On Fri, 23 Jul 2004 13:54:31 -0400, Gord Philpott <[EMAIL PROTECTED]> wrote:

Hello all,

I'm setting up bincimap 1.2.8final for a qmail / vpopmail server running on Solaris 5.7.

I'm looking for a way to automatically create a symlink from:
   IMAPdir/INBOX --> ../Maildir


I have been playing around with the /services/imap/run file for binc by adding a line which calls a linkwrapper file.
The /services/imap/run file contains:
#!/bin/sh
# $Id: run-ssl.in,v 1.1.1.1 2003/08/18 18:06:05 andreaha Exp $
# daemontools supervise run-file for Binc IMAP Service.


   exec 2>&1

   exec    tcpserver -c 100 -u 0 -g 0              \
       -l $(hostname) -HDRP                        \
       0 143                                       \
       /var/qmail/bin/bincimap-up                  \
       --logtype=multilog                          \
       --conf=/var/qmail/control/bincimap.conf --  \
       /export/home/vpopmail/bin/vchkpw            \
       /var/qmail/bin/linkwrapper                  \
       /var/qmail/bin/bincimapd

I don't know anything about vchkpw and was not able to find much information through google. Does it work like checkvpw? In that case you probably need to add "IMAPdir" as an argument to bincimapd as explained in http://lifewithbincimap.org/index.php/Main/LifeWithCheckpasswordAndFriends.

The best way to check this is to run the command:
    echo "user\0pass\0time\0" |
      /export/home/vpopmail/bin/vchkpw 3<&0 \
      /var/qmail/bin/linkwrapper \
      pwd
What is the result of running this command?

What about if you run:
    echo "user\0pass\0time\0" |
      /export/home/vpopmail/bin/vchkpw 3<&0 \
      /var/qmail/bin/linkwrapper \
      pwd IMAPdir


And the /var/qmail/bin/linkwrapper file contains: #!/bin/sh test ! -d IMAPdir && mkdir IMAPdir test ! -h IMAPdir/INBOX && ln -s ../Maildir IMAPdir/INBOX exec $@



I currently have bincimap setup with the following bincimap.conf file:
   Mailbox {
     depot = "IMAPdir",
     type = "Maildir",
     path = "IMAPdir",
     auto create inbox = "no",
     auto subscribe mailboxes = "INBOX",
     umask = "077"
   }


Running the /var/qmail/bin/linkwrapper file as the vpopmail user while in the /export/home/vpopmail/domains/DOMAINNAME.TLD/username directory properly creates the IMAPdir and symlink to the ../Maildir folder.



With the /var/qmail/bin/linkwrapper line removed from the imap/run script, and manually running the linkwrapper script in the user's vpopmail directory, bincimap works perfect. (I am able to login via telnet to port 143 and select the inbox).


When I have the linkwrapper line in the imap/run script and telnet to port 143, I receive an error stating:
a2 NO SELECT failed: No such mailbox "INBOX"
But the symlink for INBOX --> ../Maildir is present.


Does Maildir exist?  Is it a valid Maildir?

Henry :-)

server# telnet localhost 143
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
* OK Welcome to Binc IMAP Copyright (C) 2002-2004 Andreas Aardal Hanssen at 2004-07-23 13:02:05 EDT
a1 login [EMAIL PROTECTED] testpass
a1 OK LOGIN completed
a2 select inbox
a2 NO SELECT failed: No such mailbox "INBOX"
a3 logout
* BYE Binc IMAP shutting down
a3 OK LOGOUT completed
Connection closed by foreign host.
server#


Any comments are welcome.
--Gord.




-- Henry Baragar Instantiated Software Inc. http://www.instantiated.ca

Reply via email to