Persistent "write EPIPE" error on Mail operation - Directus on Dokploy (Hostinger VPS)

Hi everyone,

I’m facing a persistent write EPIPE error whenever I try to send an email through a Directus “Mail” operation. I’ve tried every possible SMTP configuration, but the error remains the same.

My Setup:

  • Platform: Directus (latest) running on Dokploy.

  • Infrastructure: Hostinger VPS.

  • Email Provider: Hostinger SMTP (smtp.hostinger.com).

The Error:

JSON

{
  "type": "Error",
  "message": "write EPIPE",
  "code": "EPIPE",
  "syscall": "write"
}

What I’ve tried so far:

  1. Ports & Security: Tested Port 465 (Secure: true) and Port 587 (Secure: false).

  2. Connectivity: Verified connectivity via Terminal inside the container using nc -zv smtp.hostinger.com 465 (Connection is Open).

  3. Environment Variables: Configured EMAIL_SMTP_POOL=false, EMAIL_SMTP_IGNORE_TLS=false, and EMAIL_SMTP_TLS_REJECT_UNAUTHORIZED=false.

  4. Network Tweaks: Added NODE_OPTIONS="--dns-result-order=ipv4first".

  5. External Relays: Tried Resend SMTP, but surprisingly got the same EPIPE error.

  6. Redeploy: Performed a full “Redeploy” in Dokploy after every change to ensure environment variables are injected.

Observations: Even after deleting all mail-related environment variables, the error persists as EPIPE instead of a “Missing Configuration” error, which makes me suspect that Directus might be caching old configs or ignoring environment variables in this specific Docker setup.

Has anyone encountered this on Dokploy or similar VPS environments?

Any help would be greatly appreciated!