<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[listmonk: outgoing Message-ID uses localhost.localdomain]]></title><description><![CDATA[<p dir="auto">Hi,</p>
<p dir="auto">All campaign emails sent from the listmonk app leave with a<br />
Message-ID header pointing at <code>localhost.localdomain</code>, e.g.:</p>
<pre><code>  Message-ID: &lt;1776433035469678859.1.4025817209405639301@localhost.localdomain&gt;
</code></pre>
<p dir="auto">This is a minor but real deliverability smell — some spam filters<br />
have heuristics against it, and it's unambiguously a misconfiguration.</p>
<h2>Root cause</h2>
<p dir="auto">listmonk uses the <code>knadh/smtppool</code> library. In<br />
<code>smtppool/email.go :: generateMessageID()</code>:</p>
<pre><code>  h, err := os.Hostname()
  if err != nil || !strings.Contains(h, ".") {
      h = defaultHostname   // = "localhost.localdomain"
  }
</code></pre>
<p dir="auto"><a href="https://github.com/knadh/smtppool/blob/master/email.go" target="_blank" rel="noopener noreferrer nofollow ugc">https://github.com/knadh/smtppool/blob/master/email.go</a></p>
<p dir="auto">app UUID (e.g. <code>9983cd4c-e53c-436e-af86-84bdbc749178</code>) — no dot,<br />
so smtppool falls back to the hardcoded <code>localhost.localdomain</code>.</p>
<p dir="auto">The "EHLO hostname" setting in listmonk admin does <strong>not</strong> help —<br />
smtppool uses it only for the SMTP handshake, not for Message-ID<br />
generation (two separate fields in the library).</p>
<h2>Proposed fix (Cloudron package, one-liner)</h2>
<p dir="auto">Set the container hostname to <code>CLOUDRON_APP_DOMAIN</code> — either via<br />
<code>--hostname</code> at run time, or <code>hostname "$CLOUDRON_APP_DOMAIN"</code> at<br />
the top of the start script. Message-ID then becomes<br />
<code>&lt;…@listen.example.com&gt;</code> instead of <code>@localhost.localdomain</code>.</p>
<p dir="auto">An upstream config option in listmonk/smtppool would be the proper<br />
fix, but the Cloudron-side workaround resolves it immediately for<br />
all Cloudron listmonk users.</p>
<h2>Environment</h2>
<ul>
<li>Cloudron: 9.0.0</li>
<li>listmonk app image: <code>cloudron/app.listmonk.cloudronapp:202603300219460000</code></li>
</ul>
<p dir="auto">Happy to test a patched build. Thanks!</p>
]]></description><link>https://forum.cloudron.io/topic/15410/listmonk-outgoing-message-id-uses-localhost.localdomain</link><generator>RSS for Node</generator><lastBuildDate>Fri, 17 Apr 2026 23:37:56 GMT</lastBuildDate><atom:link href="https://forum.cloudron.io/topic/15410.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 17 Apr 2026 20:19:19 GMT</pubDate><ttl>60</ttl></channel></rss>