Is it possible to override the value of Postfix' LDAP related parameters like "result_attribute"? #4207
-
I could not find a way to replace "result_attribute = mail" in ldap-users.cf with "result_attribute = mailbox" via my mailserver.env file. The mailbox-name currently being served by my existing LDAP server for a user "Ravi Prakash" is "ravip", while the email address is of the form [email protected]. I tried adding "POSTFIX_RESULT_ATTRIBUTE=mailbox" in mailserver.env file before running docker compose up. But still the above-mentioned file takes the result attribute as "mail" only. I want to know whether there is a neat way to change such parameters of underlying services like Postfix, Dovecot, Fetchmail etc. via the mailserver.env file, even if it is not explicitly mentioned in the sample file distributed with docker-mailserver. Thanks in advance. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
I have not looked at LDAP support for a while, but if the ENV override support presently does not support this, you can manually override a config file. I do have a PR for LDAP that improves this support (both file and ENV) but have higher priorities at present unfortunately so I am not sure when that'll land. In our test suite for LDAP we provide both config files and ENV: In the test file for LDAP, there are plenty of notes you may be interested in referencing, it notes that you should be able to override docker-mailserver/test/tests/serial/mail_with_ldap.bats Lines 41 to 44 in 2bcc5cf |
Beta Was this translation helpful? Give feedback.
I have not looked at LDAP support for a while, but if the ENV override support presently does not support this, you can manually override a config file. I do have a PR for LDAP that improves this support (both file and ENV) but have higher priorities at present unfortunately so I am not sure when that'll land.
In our test suite for LDAP we provide both config files and ENV:
docker-mailserver/test/config/ldap/overrides/ldap-users.cf
Line 6 in 2bcc5cf
In the test file for LDAP, there are plenty of notes you may be interested in referencing, it notes that you should be able to override
result_attribute
but that it will apply to all configs, thus my P…