eaudeweb / docker.postfix.satellite

Docker postfix satellite configuration (send email through a smarthost like Gmail)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Postfix satellite host

This image does not send emails (dumb host), it uses another smarthost such as Gmail to send the actual emails. Uses postfix queue features to retry sending temporary failed emails.

This has been tested with Gmail.

Configuration

TZ=Europe/Bucharest
MAIL_SMARTHOST_HOSTNAME=smtp-relay.gmail.com
MAIL_SMARTHOST_PORT=587
MAIL_SMARTHOST_USERNAME=email.address@gmail.com
MAIL_SMARTHOST_PASSWORD=secret
MAIL_DOMAIN=example.com

Gmail 2FA

Sending email through Gmail with 2FA active you need to:

  1. enable "less secure apps", read here: https://support.google.com/accounts/answer/6010255
  2. Generate an password to use instead of your Gmail password, read here: https://support.google.com/mail/answer/185833

Volumes

Use exposed volumes from /var/log and /var/spool/postfix to persist postfix state

Bibliography

About

Docker postfix satellite configuration (send email through a smarthost like Gmail)


Languages

Language:Shell 100.0%