2018-02-07 12:01:12 -08:00
The Postfix default configuration can easily be extended by providing a `config/postfix-main.cf` in postfix format.
2017-06-06 18:29:53 +02:00
This can also be used to add configuration that is not in our default configuration.
2018-02-07 12:01:12 -08:00
For example, one common use of this file is for increasing the default maximum message size:
```
# increase maximum message size
message_size_limit = 52428800
```
2019-08-21 10:39:20 +02:00
That specific example is now supported and can be handled by setting POSTFIX_MESSAGE_SIZE_LIMIT.
2016-05-19 13:30:20 +02:00
[Postfix documentation ](http://www.postfix.org/documentation.html ) remains the best place to find configuration options.
2016-05-19 13:28:04 +02:00
2017-06-06 18:29:53 +02:00
Each line in the provided file will be loaded into postfix.
2016-05-19 13:28:04 +02:00
2019-11-10 10:10:32 +01:00
In the same way it is possible to add a custom `config/postfix-master.cf` file that will override the standard `master.cf` . Each line in the file will be passed to `postconf -P` . The expected format is service_name/type/parameter, for example:
```
submission/inet/smtpd_reject_unlisted_recipient=no
```
Run `postconf -P` in the container without arguments to see the active master options.
2019-11-10 10:12:55 +01:00
Note! There should be no space between the parameter and the value.
2017-06-06 18:29:53 +02:00
Have a look at the code for more information.