* [PATCH pmg-api] fix missing postfix welcomelist update
@ 2026-06-10 7:39 Dominik Csapak
2026-06-10 9:00 ` applied: " Stoiko Ivanov
0 siblings, 1 reply; 2+ messages in thread
From: Dominik Csapak @ 2026-06-10 7:39 UTC (permalink / raw)
To: pmg-devel
Similar fix as
17f17bc (config: do not shortcircuit smtp-welcomelist generation)
If `$changes` is already true, 'rewrite_postfix_welcomelist' will never
called.
This prevented those file generation on first boot after a fresh
install.
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
---
I tested the previous fix only after rebooting the machine, not on a new
installation so I missed this.
This time I installed fresh (in debug mode) and injected the changes
into the file after the installation finished, but before a reboot and
it worked now. Sorry, I could have caught this the first time around...
src/PMG/Config.pm | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/PMG/Config.pm b/src/PMG/Config.pm
index f48c31d..9b22b67 100644
--- a/src/PMG/Config.pm
+++ b/src/PMG/Config.pm
@@ -1916,7 +1916,7 @@ sub rewrite_config_postfix {
postmap_tls_policy();
postmap_tls_inbound_domains();
- $changes ||= rewrite_postfix_welcomelist($rulecache) if $rulecache;
+ $changes = 1 if $rulecache && rewrite_postfix_welcomelist($rulecache);
# make sure aliases.db is up to date
system('/usr/bin/newaliases');
--
2.47.3
^ permalink raw reply related [flat|nested] 2+ messages in thread
* applied: [PATCH pmg-api] fix missing postfix welcomelist update
2026-06-10 7:39 [PATCH pmg-api] fix missing postfix welcomelist update Dominik Csapak
@ 2026-06-10 9:00 ` Stoiko Ivanov
0 siblings, 0 replies; 2+ messages in thread
From: Stoiko Ivanov @ 2026-06-10 9:00 UTC (permalink / raw)
To: pmg-devel, Dominik Csapak
Thanks for catching this!
reproduced the issue by - removing all of the smtp-welcomelist files (and
their postmap output - senderaccess, rcptaccess, clientaccess,
postscreen_access) and changing something in master.cf (adding -v to one
of the processes) and rebooting.
As talked off-list - the side-effects `||=` have caused issues before:
991d8f1c ("pmg-daily: avoid short-circuting update of local channels")
(despite fixing this back then I did not remember it now..)
I'll send a follow-up on-list that replaces ||= with your version -
it reads nicer too.
On Wed, 10 Jun 2026 09:39:16 +0200, Dominik Csapak wrote:
> Similar fix as
> 17f17bc (config: do not shortcircuit smtp-welcomelist generation)
>
> If `$changes` is already true, 'rewrite_postfix_welcomelist' will never
> called.
>
> This prevented those file generation on first boot after a fresh
> install.
>
> [...]
Applied, thanks!
[1/1] fix missing postfix welcomelist update
commit: 2ab0c72b8f536cb2a80a3b0561b1705ef67bc052
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-06-10 9:00 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-10 7:39 [PATCH pmg-api] fix missing postfix welcomelist update Dominik Csapak
2026-06-10 9:00 ` applied: " Stoiko Ivanov
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox