Open twitchyliquid64 opened 9 years ago
I'll start to look for that one when I get back from work
Aften looking at a few things I won't take care of that for now
In progress on the fetch branch.
In the branch lmtp
(which contains all commits of fetch
at moment of writing), I've created a Mailstore implementation, which does a pretty nice job.This will allow you to send e-mails to Postfix (which in return, sends it to the IMAP server), in order to test the FETCH
command on real-life e-mails.
Running demo/complete/main.go
might be helpful. I had to hardcode a directory in line 17, to create a persistent database, so you may have to change that. It runs together with Postfix, which you can configure by doing:
In /etc/postfix/master.cf
, replace:
lmtp unix - - - - - lmtp
with
lmtp unix - - n - - lmtp
(this causes LMTP to run non-chrooted, and thus have access to the socket.
In /etc/postfix/main.cf
, make sure you set these variables:
# This single line can contain more entries, but should contain these:
mydestination = localhost.localdomain, localhost, example.local
mailbox_transport = lmtp:inet:localhost:61194
local_recipient_maps =
Arguments: sequence set message data item names or macro
Responses: untagged responses: FETCH
Result: OK - fetch completed NO - fetch error: can't fetch that data BAD - command unknown or arguments invalid