Postfix-Relay
Postfix-Relay
Docker app from ZappyZap's Repository
Overview
This runs Postfix (as a relay) in Docker.
Most home ISPs block port 25, so outbound emails must be relayed through an external SMTP server (e.g., Gmail).
This container acts as a single collections point for devices needing to send email.
⚠️ Postfix acts as an open relay. As such, this is not meant to be run on the internet, only on a trusted internal network! ⚠️
Requirements
You must already have a account on an external SMTP server (e.g., Gmail, AWS SES, etc...).
Your external SMTP server must be using encryption (i.e., plaintext is not allowed)
Runtime arguments
- Network
bridge- Shell
sh- Privileged
- false
- Extra Params
--restart unless-stopped
Template configuration
Data DirectoryPathrw
Used to store Postfix's mail spool
- Target
- /var/spool/postfix
Postfix SMTP serverPorttcp
- Target
- 25
- Default
- 25
- Value
- 25
TimezoneVariable
- Target
- TZ
- Default
- America/New_York
- Value
- America/New_York
Public SMTPVariable
Public SMTP server to use must be using encryption (i.e., plaintext is not allowed)
- Target
- RELAY_HOST
Relay PortVariable
Public SMTP port to use
- Target
- RELAY_PORT
SMTP usernameVariable
Address to login to $RELAY_HOST
- Target
- RELAY_USER
SMTP passwordVariable
Password to login to $RELAY_HOST If using Gmail 2FA, you will need to setup an app password
- Target
- RELAY_PASS
Test Email addressVariable
Address to receive test email If not set, test email will not be sent
- Target
- TEST_EMAIL
Domain from addressVariable
Domain of the from address
- Target
- MYORIGIN
NetworksVariable
Networks that Postfix will forward mail for
- Target
- MYNETWORKS
- Default
- 0.0.0.0/0
From AddressVariable
Changes the email from address
- Target
- FROMADDRESS
Categories
Download Statistics
1,300,897
Total Downloads
16,587
This Month
10,845
Avg / Month
Total Downloads Over Time
Loading chart...
Details
Repository
loganmarchione/docker-postfixrelay:latestLast Updated2026-05-03
First Seen2022-11-14
Run Postfix-Relay on Unraid.
Postfix-Relay is listed in Community Apps for Unraid OS. Explore Unraid to build a flexible home server, NAS, or homelab.