Overview
OpenSRE can send email through any existing SMTP relay you already use. You do not need to run your own mail server. Typical providers:- Google Workspace / Gmail SMTP
- Microsoft 365 SMTP
- AWS SES SMTP
- SendGrid / Postmark / Mailgun SMTP
- local dev SMTP sinks like Mailpit or MailHog
Prerequisites
- An SMTP host you can reach from OpenSRE
- A sender address the relay will accept
- Optional username/password if the relay requires auth
Setup
Option 1: CLI wizard
- SMTP host
- SMTP port
- security mode:
starttls,ssl, ornone - optional username/password
- sender address
- optional default recipient
Option 2: Environment variables
If authentication is required, set both
SMTP_USERNAME and SMTP_PASSWORD.
Credentials
Use any SMTP relay your org already trusts. For local testing, Mailpit is a good fake SMTP target:Verify
- connect to the SMTP server
- negotiate TLS when configured
- authenticate when credentials are provided
Troubleshooting
Security
- Prefer app passwords / SMTP credentials scoped to a mailer account.
- Store passwords in
.envor your secret manager — not in source control. - Use
starttlsorsslin production; reservenonefor local sinks.