Issue running ihasmail locally via Podman #291

Open
opened 2026-09-06 16:29:47 +00:00 by QVBU · 0 comments

Hi all,
I am trying to run ihasmail locally for testing purposes inside a VMware virtual machine using Podman.Instead of a domain name, my Stalwart mail server is running on a local IP address: 192.168.122.181.I launched the ihasmail container using the following Podman command (with TLS verification disabled since it's a local test environment):
NODE_TLS_REJECT_UNAUTHORIZED=0

.env:

# URL of your Stalwart mail server
STALWART_URL=https://192.168.122.181
APP_SECRET=xzxzxzxzxz
TRUST_PROXY=1
TRUSTED_PROXIES=127.0.0.4
IMMUTABLE=1
SESSION_FILE=

The container starts up completely fine. However, right after I enter my login credentials into the ihasmail web UI, the authentication fails, and I get the following error in the logs:

2026-09-06T18:27:26.509992+02:00 vm ihasmail[5376]: [ihasmail] upstream failure: TypeError: fetch failed
2026-09-06T18:27:26.510490+02:00 vm ihasmail[5376]:     at node:internal/deps/undici/undici:15157:13
2026-09-06T18:27:26.510598+02:00 vm ihasmail[5376]:     at process.processTicksAndRejections (node:internal/process/task_queues:103:5)
2026-09-06T18:27:26.510682+02:00 vm ihasmail[5376]:     at async fetchUpstreamSession (file:///app/server/dist/upstream.js:40:17)
2026-09-06T18:27:26.510885+02:00 vm ihasmail[5376]:     at async Object.handler (file:///app/server/dist/app.js:207:30)
2026-09-06T18:27:26.510975+02:00 vm ihasmail[5376]:     at async dispatch (file:///app/node_modules/hono/dist/compose.js:22:17)
2026-09-06T18:27:26.511064+02:00 vm ihasmail[5376]:     at async handler (file:///app/node_modules/hono/dist/hono-base.js:119:39)
2026-09-06T18:27:26.511171+02:00 vm ihasmail[5376]:     at async dispatch (file:///app/node_modules/hono/dist/compose.js:22:17)
2026-09-06T18:27:26.511263+02:00 vm ihasmail[5376]:     at async Object.csrfGuard [as handler] (file:///app/server/dist/app.js:98:5)
2026-09-06T18:27:26.511347+02:00 vm ihasmail[5376]:     at async dispatch (file:///app/node_modules/hono/dist/compose.js:22:17)
2026-09-06T18:27:26.511409+02:00 vm ihasmail[5376]:     at async handler (file:///app/node_modules/hono/dist/hono-base.js:119:39) {
2026-09-06T18:27:26.511480+02:00 vm ihasmail[5376]:   [cause]: Error: connect ECONNREFUSED 192.168.122.181:443
2026-09-06T18:27:26.511550+02:00 vm ihasmail[5376]:       at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1638:16) {
2026-09-06T18:27:26.511623+02:00 vm ihasmail[5376]:     errno: -111,
2026-09-06T18:27:26.511711+02:00 vm ihasmail[5376]:     code: 'ECONNREFUSED',
2026-09-06T18:27:26.511783+02:00 vm ihasmail[5376]:     syscall: 'connect',
2026-09-06T18:27:26.511860+02:00 vm ihasmail[5376]:     address: '192.168.122.181',
2026-09-06T18:27:26.511931+02:00 vm ihasmail[5376]:     port: 443
2026-09-06T18:27:26.512027+02:00 vm ihasmail[5376]:   }
2026-09-06T18:27:26.512090+02:00 vm ihasmail[5376]: }

Has anyone encountered this when running ihasmail locally without a proper domain?
Thanks for help!

Rebuilt from: GH Archive.

Hi all, I am trying to run ihasmail locally for testing purposes inside a VMware virtual machine using Podman.Instead of a domain name, my Stalwart mail server is running on a local IP address: 192.168.122.181.I launched the ihasmail container using the following Podman command (with TLS verification disabled since it's a local test environment): `NODE_TLS_REJECT_UNAUTHORIZED=0` .env: ``` # URL of your Stalwart mail server STALWART_URL=https://192.168.122.181 APP_SECRET=xzxzxzxzxz TRUST_PROXY=1 TRUSTED_PROXIES=127.0.0.4 IMMUTABLE=1 SESSION_FILE= ``` The container starts up completely fine. However, right after I enter my login credentials into the ihasmail web UI, the authentication fails, and I get the following error in the logs: ``` 2026-09-06T18:27:26.509992+02:00 vm ihasmail[5376]: [ihasmail] upstream failure: TypeError: fetch failed 2026-09-06T18:27:26.510490+02:00 vm ihasmail[5376]: at node:internal/deps/undici/undici:15157:13 2026-09-06T18:27:26.510598+02:00 vm ihasmail[5376]: at process.processTicksAndRejections (node:internal/process/task_queues:103:5) 2026-09-06T18:27:26.510682+02:00 vm ihasmail[5376]: at async fetchUpstreamSession (file:///app/server/dist/upstream.js:40:17) 2026-09-06T18:27:26.510885+02:00 vm ihasmail[5376]: at async Object.handler (file:///app/server/dist/app.js:207:30) 2026-09-06T18:27:26.510975+02:00 vm ihasmail[5376]: at async dispatch (file:///app/node_modules/hono/dist/compose.js:22:17) 2026-09-06T18:27:26.511064+02:00 vm ihasmail[5376]: at async handler (file:///app/node_modules/hono/dist/hono-base.js:119:39) 2026-09-06T18:27:26.511171+02:00 vm ihasmail[5376]: at async dispatch (file:///app/node_modules/hono/dist/compose.js:22:17) 2026-09-06T18:27:26.511263+02:00 vm ihasmail[5376]: at async Object.csrfGuard [as handler] (file:///app/server/dist/app.js:98:5) 2026-09-06T18:27:26.511347+02:00 vm ihasmail[5376]: at async dispatch (file:///app/node_modules/hono/dist/compose.js:22:17) 2026-09-06T18:27:26.511409+02:00 vm ihasmail[5376]: at async handler (file:///app/node_modules/hono/dist/hono-base.js:119:39) { 2026-09-06T18:27:26.511480+02:00 vm ihasmail[5376]: [cause]: Error: connect ECONNREFUSED 192.168.122.181:443 2026-09-06T18:27:26.511550+02:00 vm ihasmail[5376]: at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1638:16) { 2026-09-06T18:27:26.511623+02:00 vm ihasmail[5376]: errno: -111, 2026-09-06T18:27:26.511711+02:00 vm ihasmail[5376]: code: 'ECONNREFUSED', 2026-09-06T18:27:26.511783+02:00 vm ihasmail[5376]: syscall: 'connect', 2026-09-06T18:27:26.511860+02:00 vm ihasmail[5376]: address: '192.168.122.181', 2026-09-06T18:27:26.511931+02:00 vm ihasmail[5376]: port: 443 2026-09-06T18:27:26.512027+02:00 vm ihasmail[5376]: } 2026-09-06T18:27:26.512090+02:00 vm ihasmail[5376]: } ``` Has anyone encountered this when running ihasmail locally without a proper domain? Thanks for help! <sub>Rebuilt from: GH Archive.</sub>
This repo is archived. You cannot comment on issues.