From 620da53fe79442d0ef8bf7264ba2fba9c6be6bca Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Mon, 3 Jan 2022 20:14:36 +0100 Subject: [PATCH] postfix: move postmap to post regenconf, because the postfix user must be able to access the file, and cant anymore during pre because we moved the pending regenconf folder elsewhere --- hooks/conf_regen/19-postfix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hooks/conf_regen/19-postfix b/hooks/conf_regen/19-postfix index 4a7325c41..e18243508 100755 --- a/hooks/conf_regen/19-postfix +++ b/hooks/conf_regen/19-postfix @@ -42,7 +42,6 @@ do_pre_regen() { chown postfix ${pending_dir}/etc/postfix/sasl_passwd cat <<<"[${relay_host}]:${relay_port} ${relay_user}:${relay_password}" >${postfix_dir}/sasl_passwd - postmap ${postfix_dir}/sasl_passwd fi export main_domain export domain_list="$YNH_DOMAINS" @@ -71,6 +70,7 @@ do_post_regen() { if [ -e /etc/postfix/sasl_passwd ]; then chmod 750 /etc/postfix/sasl_passwd* chown postfix:root /etc/postfix/sasl_passwd* + postmap /etc/postfix/sasl_passwd fi [[ -z "$regen_conf_files" ]] \