Gnus development mailing list
 help / color / mirror / Atom feed
From: Christian Barthel <bch@online.de>
To: ding@gnus.org
Cc: Emanuel Berg <moasenwood@zoho.eu>
Subject: Re: set up Gnus to work with a remote system mailserver (with Dovecot?)
Date: Thu, 07 Apr 2022 11:31:05 +0200	[thread overview]
Message-ID: <87k0c1p7dy.fsf@online.de> (raw)
In-Reply-To: <87fsmp1yk9.fsf@zoho.eu> (Emanuel Berg's message of "Thu, 07 Apr 2022 03:17:58 +0200")

On Thursday, April 07, 2022, Emanuel Berg wrote:

> Anyone knows to setup Gnus to work with a remote system mailserver?
> I've heard it is IMAP and you are supposed to do accomplish this with
> something called Dovecot. [..]

nnimap is the way to go, see (info "(gnus) Using IMAP")

As far as I remember, the system you’re referring to does not expose 
Dovecot on a TCP port nor does it run Dovecot as a daemon.  In this
case, you can use the Dovecot imap binary.  The configuration should be
something like this:

--8<---------------cut here---------------start------------->8---
(setq gnus-select-method
  '(nnimap "Mail"
   (nnimap-stream shell)
   (nnimap-shell-program
      "ssh user@host /usr/local/libexec/dovecot/imap -o
      mail_location=maildir:~/Maildir/:LAYOUT=fs")))
--8<---------------cut here---------------end--------------->8---

(remove the “ssh user@host” if you’re working locally)

So, instead of talking with an IMAP Service on a network socket, it
executes the shell command and reads mails from there (stdin/stdout).
Make sure to setup ~/Maildir/ i.e. your incoming mail must be directed
into the ~/Maildir folder.

To redirect your incoming mail to fdm(1), you have to setup the
“.forward” file in your home directory:

--8<---------------cut here---------------start------------->8---
# cat ~/.forward
|/usr/local/bin/fdm -m -a stdin fetch
--8<---------------cut here---------------end--------------->8---

With fdm(1), something like this should work:

--8<---------------cut here---------------start------------->8---
# cat ~/.fdm.conf
action "inbox" maildir "/home/username/Maildir/"
match all action "inbox"
--8<---------------cut here---------------end--------------->8---

And then, you have to setup SMTP to send emails.


Some additional pointers:
https://github.com/nicm/fdm/blob/master/MANUAL#L730
https://dovecot.org/pipermail/dovecot/2009-February/037682.html
https://ding.gnus.narkive.com/8JpLY6yI/how-to-debug-nnimap-stream-shell
   (haven’t used that but that seems helpful for debugging)
-- 
Christian Barthel


  parent reply	other threads:[~2022-04-07  9:31 UTC|newest]

Thread overview: 57+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-07  1:17 Emanuel Berg
2022-04-07  2:34 ` Byung-Hee HWANG
2022-04-07  3:08   ` Emanuel Berg
2022-04-07  7:47     ` Andreas Schwab
2022-04-07  8:07       ` Emanuel Berg
2022-04-07  8:12         ` Emanuel Berg
2022-04-07  8:27           ` Emanuel Berg
2022-04-10 11:47             ` Byung-Hee HWANG
2022-04-10 13:13               ` Emanuel Berg
2022-04-11  3:47                 ` Byung-Hee HWANG
2022-04-11  4:03                   ` Byung-Hee HWANG
2022-04-11 22:55                     ` Bob Newell
2022-04-12  2:18                       ` Byung-Hee HWANG
2022-04-12  8:30                       ` Eric S Fraga
2022-04-12  6:00                   ` Emanuel Berg
2022-04-12  6:34                     ` Emanuel Berg
2022-04-19 23:53                     ` Emanuel Berg
2022-04-20  0:11                       ` Emanuel Berg
2022-04-21 12:38                         ` Byung-Hee HWANG
2022-04-21 13:16                           ` Emanuel Berg
2022-04-21 13:30                             ` Byung-Hee HWANG
2022-04-21 13:41                               ` Emanuel Berg
2022-04-27 20:15                               ` Emanuel Berg
2022-04-27 20:27                                 ` Emanuel Berg
2022-04-28  3:44                                 ` Byung-Hee HWANG
2022-05-03  2:36                                   ` Emanuel Berg
2022-05-03  6:36                                     ` Byung-Hee HWANG
2022-05-03  7:01                                       ` Emanuel Berg
2022-05-03  7:17                                         ` Byung-Hee HWANG
2022-05-04  0:11                                           ` Emanuel Berg
2022-05-04 11:50                                     ` expiring in nnselect groups not saved Erik Colson
2022-05-04 17:01                                       ` Eric Abrahamsen
2022-05-04 21:47                                         ` Erik Colson
2022-05-05  0:39                                           ` Andrew Cohen
2022-05-05  0:48                                             ` Andrew Cohen
2022-05-05  2:07                                               ` Andrew Cohen
2022-05-05 10:10                                             ` Erik Colson
2022-05-05 10:48                                               ` Erik Colson
2022-05-05 11:09                                                 ` Erik Colson
2022-05-05 11:21                                                   ` Erik Colson
2022-05-05 12:20                                                     ` Erik Colson
2022-05-05 20:59                                                       ` Erik Colson
2022-05-06  0:49                                                         ` Andrew Cohen
2022-05-06 15:42                                                           ` Erik Colson
2022-05-06 16:27                                                             ` Erik Colson
2022-04-07  8:51 ` set up Gnus to work with a remote system mailserver (with Dovecot?) Uwe Brauer
2022-04-07  8:58   ` Emanuel Berg
2022-04-07 10:28   ` Eric S Fraga
2022-04-07 16:43     ` Russ Allbery
2022-04-08 10:03       ` Eric S Fraga
2022-04-08 11:59         ` Emanuel Berg
2022-04-07  9:31 ` Christian Barthel [this message]
2022-04-07 10:57   ` Emanuel Berg
2022-04-09 23:23   ` Emanuel Berg
2022-04-21  1:42   ` Emanuel Berg
2022-04-21  2:52     ` Emanuel Berg
2022-04-21  2:54     ` Emanuel Berg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87k0c1p7dy.fsf@online.de \
    --to=bch@online.de \
    --cc=ding@gnus.org \
    --cc=moasenwood@zoho.eu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).