|
| 1 | +# postfix []() |
1 | 2 |
|
2 | | -postfix mail server with configurable hostname and trusted hosts and proper |
3 | | -shutdown handling |
| 3 | +This is project implements as a docker container a postfix mail server. It supports a configurable hostname, trusted hosts, proper |
| 4 | +shutdown handling and mail relay (e.g. to mailgun). |
4 | 5 |
|
5 | | -Notes |
6 | | -=== |
| 6 | +## Notes |
7 | 7 |
|
8 | 8 | By default, connected rfc1918 networks are detected and allowed. Local networks |
9 | 9 | (127.0.0.1, ::1) are also allowed. |
10 | 10 |
|
11 | | -Syslog |
12 | | -=== |
| 11 | +## Syslog |
13 | 12 |
|
14 | 13 | Rsyslog is started automatically and sends logs to stdout |
15 | 14 |
|
16 | | -Suggested Volumes |
17 | | -=== |
| 15 | +## Suggested Volumes |
18 | 16 |
|
19 | 17 | * `/var/spool/postfix` is the spool directory. Its also where postfix chroots to by default. |
20 | 18 | * `/etc/postfix` is the configuation directory |
21 | 19 |
|
22 | | -Options |
23 | | -=== |
| 20 | +## Configuration |
24 | 21 |
|
25 | 22 | You can customize the image behavior using environmental variables or entrypoint |
26 | 23 | arguments. |
27 | 24 |
|
28 | | -<table> |
29 | | - <thead> |
30 | | - <th>Enviromental Variable(s)</th> |
31 | | - <th>Entrypoint Option</th> |
32 | | - <th>Description</th> |
33 | | - </thead> |
34 | | - <tbody> |
35 | | - <tr> |
36 | | - <td>(use <code>--hostname</code>)</td> |
37 | | - <td><code>--mail-name</code></td> |
38 | | - <td>Mail name to use (appears in mail headers). Defaults to hostname</td> |
39 | | - </tr> |
40 | | - <tr> |
41 | | - <td>RELAYHOST="[relay hostname]</td> |
42 | | - <td><code>--relayhost []</code></td> |
43 | | - <td>The host to relay mail to.</td> |
44 | | - </tr> |
45 | | - <tr> |
46 | | - <td><code>TRUST="local"</code> or <code>TRUST_LOCAL="0"</code></td> |
47 | | - <td><code>--trust-local</code></td> |
48 | | - <td>Trust addresses on the lo interface. Enabled by default</td> |
49 | | - </tr> |
50 | | - <tr> |
51 | | - <td><code>TRUST="connected-rfc1918"</code> or <code>TRUST_CONNECTED_RFC="1"</code></td> |
52 | | - <td><code>--trust-connected-rfc1918</code></td> |
53 | | - <td>Trust all locally connected rfc1918 subnets. Enabled by default</td> |
54 | | - </tr> |
55 | | - <tr> |
56 | | - <td><code>TRUST="connected"</code> or <code>TRUST_CONNECTED="1"</td> |
57 | | - <td><code>--trust-connected</code></td> |
58 | | - <td>Trust all addresses connected (excluding IPv6 local-link addresses). Disabled by default</td> |
59 | | - </tr> |
60 | | - <tr> |
61 | | - <td><code>TRUST="rfc1918"</code> or <code>TRUST_RFC1918="1"</td> |
62 | | - <td><code>--trust-rfc1918</code></td> |
63 | | - <td>Trust all rfc1918 address. Disabled by default</td> |
64 | | - </tr> |
65 | | - <tr> |
66 | | - <td><code>TRUST_LLA="1"</code></td> |
67 | | - <td><code>--trust-lla</code></td> |
68 | | - <td>Trust the fe80::/64 IPv6 subnet. Disabled by default</td> |
69 | | - </tr> |
70 | | - <tr> |
71 | | - <td><code>TRUST_SUBNETS="[space separated list of subnets]"</code></td> |
72 | | - <td><code>--trust-subnet []</code></td> |
73 | | - <td>Trust the specified subnet (IPv4 and IPv6 supported). Disabled by default</td> |
74 | | - </tr> |
75 | | - <tr> |
76 | | - <td><code>TRUST_INTERFACES="[space separated list of interfaces]"</code></td> |
77 | | - <td><code>--trust-interface []</code></td> |
78 | | - <td>Trust all network address on the interface (excluding IPv6 LLA). Disabled by default</td> |
79 | | - </tr> |
80 | | - <tr> |
81 | | - <td></td> |
82 | | - <td><code>--skip-trust-</code>*</td> |
83 | | - <td>Use with local, connected-rfc1918, connected, rfc1918, or lla to skip trusting it. Disabled by default</td> |
84 | | - </tr> |
85 | | - <tr> |
86 | | - <td></td> |
87 | | - <td><code>--skip-all</code></td> |
88 | | - <td>Disable/reset all trusts. Disabled by default</td> |
89 | | - </tr> |
90 | | - </tbody> |
91 | | -</table> |
| 25 | + |
| 26 | +| Enviromental Variable(s) | Entrypoint Option | Description | |
| 27 | +|---------------------------------------------------------|--------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------| |
| 28 | +| (use --hostname) | --mail-name | Mail name to use (appears in mail headers). Defaults to hostname | |
| 29 | +| RELAYHOST="[relay hostname] | --relayhost [] | The host to relay mail to. | |
| 30 | +| TRUST="local" or TRUST_LOCAL="0" | --trust-local | Trust addresses on the lo interface. Enabled by default | |
| 31 | +| TRUST="connected-rfc1918" or TRUST_CONNECTED_RFC="1" | --trust-connected-rfc1918 | Trust all locally connected rfc1918 subnets. Enabled by default | |
| 32 | +| TRUST="connected" or TRUST_CONNECTED="1" | --trust-connected | Trust all addresses connected (excluding IPv6 local-link addresses). Disabled by default | |
| 33 | +| TRUST="rfc1918" or TRUST_RFC1918="1" | --trust-rfc1918 | Trust all rfc1918 address. Disabled by default | |
| 34 | +| TRUST_LLA="1" | --trust-lla | Trust the fe80::/64 IPv6 subnet. Disabled by default | |
| 35 | +| TRUST_SUBNETS="[space separated list of subnets]" | --trust-subnet [] | Trust the specified subnet (IPv4 and IPv6 supported). Disabled by default | |
| 36 | +| TRUST_INTERFACES="[space separated list of interfaces]" | --trust-interface [] | Trust all network address on the interface (excluding IPv6 LLA). Disabled by default | |
| 37 | +| | --skip-trust-* | `local`, `connected-rfc1918`, `connected`, `rfc1918`, or `lla` to skip trusting it. | |
| 38 | +| | --skip-all | Disable/reset all trusts. Disabled by default | |
| 39 | + |
| 40 | + |
0 commit comments