19 Oct
2014
19 Oct
'14
1:32 a.m.
Maybe off-topic, still: (If your remote server is imap,) why not use fetchmail?
Here's a mangled/working /etc/fetchmailrc for an SSL imap account:
poll smtp.provider.net protocol IMAP port 993 user 'somone@somewhere.com' is 'someone' here password 'MyPass123' folder 'INBOX' fetchall idle ssl
mda "HOME=/home/%T /usr/bin/sudo -u %T /usr/lib/dovecot/deliver"
## cf. /etc/sudoers.d/fetchmail-deliver #fetchmail ALL=(ALL) NOPASSWD:/usr/lib/dovecot/deliver
This uses imap idle over there and fetches new mail, as it arrives. Local users will be notified of new mail without looking explicitly…
-- peter