bob B writes:
I am using the docker images provided by the mailman project.
OK.
The containers are up and running
CONTAINER ID PORTS NAMES 9dbad91fe50b 127.0.0.1:8000->8000/tcp, 127.0.0.1:8080->8080/tcp mailman-web 7005bf66498e 127.0.0.1:8001->8001/tcp, 127.0.0.1:8024->8024/tcp mailman-core b5336023fa94 5432/tcp dockermailman_database_1
That all appears correct. Most important, dockerhost says it is forwarding port 8024 to port 8024 on the mailman-core container.
I have been digging in more and it looks like the mailman-core is not processing or accepting mail or/and the connection gets lost.
Yes. It's possible the LMTP module is somehow broken in Mailman core but I can't imagine why that would be.
But I can send mail from mailman in docker.
Containers are much more strict about incoming connections than they are about outgoing connections to the dockerhost. Since Postfix handles outgoing mail for Mailman, but Mailman handles incoming LMTP itself, this is not particularly surprising.
On the docker host my /etc/postfix/main.cf has
transport_maps = regexp:/opt/mailman/core/var/data/postfix_lmtp local_recipient_maps = regexp:/opt/mailman/core/var/data/postfix_lmtp relay_domains = regexp:/opt/mailman/core/var/data/postfix_domains
These appear to be working correctly.
mailman-core: image: maxking/mailman-core:0.3 container_name: mailman-core hostname: mailman-core . . ports:
- "127.0.0.1:8001:8001" # API
- "127.0.0.1:8024:8024" # LMTP - incoming emails
This is obviously the configuration that results in the container status output above. So that's working correctly.
But when I send a message, the docker host machine in /var/log/email/ shows "connection refused" & "lost connection" to mailman-core port 8024
Either for some reason the container is blocking this port or Mailman's LMTP server is AWOL. Aside from bugs, the only thing I can think of is that there's a configuration of LMTP to listen on a different port. This would either be in mailman.cfg, or in schema.cfg. But normally the default in schema.cfg is 8024, and there is no configuration of lmtp_port in mailman.cfg.
However, this below would indicate that it's set explicitly to 8024.
# mailman-extra.cfg
[mta] incoming: mailman.mta.postfix.LMTP outgoing: mailman.mta.deliver.deliver # mailman-core hostname or IP from the Postfix server lmtp_host: localhost lmtp_port: 8024 # Postfix server's hostname or IP from mailman-core smtp_host: outbound-mail-server.######.### smtp_port: 25 configuration: /etc/postfix-mailman.cfg [mailman]
So I'm stumped. As far as I can tell you have everything right, and mailman-extra.cfg should be included in such a way that it overrides settings in mailman.cfg and schema.cfg.
I guess you'll have to wait for Abhilash, or maybe Mark but I don't think Mark is much more familiar with the containers than I am.
Steve