Skip to content

Commit a0e0ec5

Browse files
committed
support MY_HOSTNAME to set myhostname
1 parent aa65f6e commit a0e0ec5

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ Configuration is basic and is done using the environment variables listed below
1515
* `RELAY` - DNS of your target relay host or service. Like smtp-relay.gmail.com or smtp.mailgun.com. *While optional, you won't be able to relay email if you don't set this value.*
1616
* `TLS` - Set this to "true" to enable TLS. You almost always want to do this.
1717
* `SASL_AUTH` - Authentication information for connecting to the relay host. *While optional, you likely won't be able to relay email if you don't set this value.*
18+
* `MY_HOSTNAME` - Optionally set the hostname emails will appear to come from.
1819

1920
### Example
2021

entrypoint.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,10 @@ if [[ -n "$MY_DESTINATION" ]]; then
3232
postconf -e mydestination="$MY_DESTINATION"
3333
fi
3434

35+
if [[ -n "$MY_HOSTNAME" ]]; then
36+
postconf -e myhostname=$MY_HOSTNAME
37+
fi
38+
3539
if [[ -n "$ROOT_ALIAS" ]]; then
3640
if [[ -f /etc/aliases ]]; then
3741
sed -i '/^root:/d' /etc/aliases

0 commit comments

Comments
 (0)