fix: Dovecot in Debian Trixie => 2.4 has add / deprecated configurations
All checks were successful
Molecule Tests / molecule-tests (pull_request) Successful in 7m18s

This commit is contained in:
2026-03-11 12:40:37 -03:00
parent 1300e7acc6
commit d61a4ddcef
9 changed files with 72 additions and 3 deletions

View File

@@ -1,5 +1,21 @@
# Dovecot local users authentication
# Ansible managed: {{ ansible_managed }}
{% if dovecot_major_version is defined and dovecot_major_version is version('2.4', '>=') %}
passdb passwd-file {
default_password_scheme = SHA512-CRYPT
auth_username_format = %{user|username}
passwd_file_path = /etc/dovecot/users
}
userdb static {
fields {
uid = vmail
gid = vmail
home = /var/vmail/%{user|username}
}
}
{% else %}
passdb {
driver = passwd-file
@@ -10,3 +26,4 @@ userdb {
driver = static
args = uid=vmail gid=vmail home=/var/vmail/%n
}
{% endif %}