Submail can be deployed in various ways depending on your infrastructure preference.
This is the easiest way to get everything running on a VPS.
.env file and populate it with production values.docker-compose up -d
This will start the web container on port 3000 and the bot container on port 25. You should put a reverse proxy (like Nginx or Traefik) in front of the web container to handle HTTPS (port 443).
Oracle Cloud offers a generous free tier that is suitable for hosting Submail.
Oracle Cloud blocks port 25 by default. You generally cannot open it for outbound traffic easily, but for inbound (receiving mail), you need to open it in two places:
Follow the Docker Compose steps above. Since this is an ARM instance, Docker will automatically pull/build the correct architecture images if the base images support it (Node.js official images do).
If you prefer Vercel for the web frontend:
apps/web directory to Vercel.
DATABASE_URL to point to a managed database (e.g., Supabase, Neon, or a Postgres on your VPS). SQLite will NOT work on Vercel.For the system to receive emails and for them to pass spam filters, you must configure DNS.
| Type | Host | Value | Purpose |
|---|---|---|---|
A |
mail |
<Your VPS IP> |
Points subdomain to server |
MX |
@ |
10 mail.yourdomain.com |
Directs email to your server |
TXT |
@ |
v=spf1 mx -all |
SPF Record (approves your server) |
TXT |
_dmarc |
v=DMARC1; p=quarantine; |
DMARC Policy |
Reverse DNS (PTR): Essential for deliverability. Configure this in your VPS provider’s networking dashboard to map your IP back to
mail.yourdomain.com.