Skip to main content
DBDock sends email via standard SMTP — any provider works.

Configuration

dbdock.config.json

.env

Multiple to addresses are supported — all recipients get every alert.

Provider setup

Important: Gmail requires an App Password, not your regular account password. Enable 2FA first, then generate an App Password for “Mail”.
The username is literally the word apikey — not your SendGrid username. The password is the API key.
SES SMTP credentials are distinct from your AWS access keys. Generate them from the SES console → SMTP Settings.Replace us-east-1 with your SES region.
Username and password are the same — both your server token.
Any SMTP server works:
Use secure: true + port: 465 for implicit TLS. Use secure: false + port: 587 for STARTTLS (most modern servers).

Email content

Success

Subject: ✓ Backup complete — myapp (45.2 MB) Body: backup ID, database, size, duration, storage path, encryption status.

Failure

Subject: ✗ Backup failed — myapp Body: error message, timestamp, troubleshooting suggestion.

Testing

Sends a test email to all to addresses. Check spam folders if it doesn’t arrive.

Common issues

  • Wrong username/password
  • Gmail: not using an App Password
  • Provider requires API key, not account password (SendGrid, Postmark)
  • Port blocked by network firewall
  • Try port 465 with secure: true instead of 587
  • Check spam folder
  • Verify from address is allowed by the provider (SendGrid/SES require domain verification)
  • Check provider’s send logs (SendGrid activity feed, SES CloudWatch)

Security

  • SMTP credentials live in .env, never in dbdock.config.json
  • DBDock uses STARTTLS when secure: false + port 587
  • If your SMTP server requires a certificate chain outside the Node defaults, you’ll need to set NODE_EXTRA_CA_CERTS

See also

Slack alerts

Real-time Slack notifications.

Custom webhooks

Discord, WhatsApp, and custom endpoints.