From 2f498c5c032af8c97d3d9e15f95bc9a053949ab7 Mon Sep 17 00:00:00 2001 From: Paul Cammish Date: Tue, 21 Sep 2021 13:34:44 +0000 Subject: [PATCH] Merge branch 'kelduum_issue317' into 'bullseye-testing' Deal with aliases correctly with no mailboxes dir See merge request sympl/sympl!239 (cherry picked from commit 1269d3dfd17e0e215a09f74326d1024eb6604472) 039436c5 Deal with aliases correctly with no mailboxes dir --- CHANGELOG | 6 +++++- mail/debian/changelog | 6 ++++++ mail/exim4/sympl.d/20-routers/22-vhost-forward | 2 +- mail/exim4/sympl.d/20-routers/24-vhost-mailbox | 2 +- 4 files changed, 13 insertions(+), 3 deletions(-) diff --git a/CHANGELOG b/CHANGELOG index 33f52308..500f6688 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,10 +1,14 @@ CHANGELOG --------- +2021-09-21 + sympl-mail: + * Deal with aliases correctly when no mailboxes directory exists + 2021-08-19 all: * Debian Bullseye Release - core: + sympl-core: * Updates to MOTD and banners 2021-08-18 diff --git a/mail/debian/changelog b/mail/debian/changelog index 8445446c..d369fbe9 100644 --- a/mail/debian/changelog +++ b/mail/debian/changelog @@ -1,3 +1,9 @@ +sympl-mail (11.20210921.1) stable; urgency=medium + + * Deal with mail correctly when no mailboxes directory exists, fixes #317 + + -- Paul Cammish Tue, 21 Sep 2021 13:58:00 +0100 + sympl-mail (11.20210818.1) stable; urgency=medium * Debian Bullseye Release diff --git a/mail/exim4/sympl.d/20-routers/22-vhost-forward b/mail/exim4/sympl.d/20-routers/22-vhost-forward index fa99ccc8..3f323aa6 100644 --- a/mail/exim4/sympl.d/20-routers/22-vhost-forward +++ b/mail/exim4/sympl.d/20-routers/22-vhost-forward @@ -5,7 +5,7 @@ vhost_forward: domains = +vhost_domains local_part_suffix = +* local_part_suffix_optional - local_parts = ${lookup{$local_part}dsearch{VHOST_DIR/$domain_data/VHOST_MAILBOX_DIR}} + local_parts = ${if exists {VHOST_DIR/$domain/VHOST_MAILBOX_DIR}{${lookup{$local_part}dsearch{VHOST_DIR/$domain_data/VHOST_MAILBOX_DIR}}}{}} # Make sure the files exists to avoid awkward failures condition = ${if exists{VHOST_DIR/$domain/VHOST_MAILBOX_DIR/$local_part/forward}} file = VHOST_DIR/$domain_data/VHOST_MAILBOX_DIR/$local_part_data/forward diff --git a/mail/exim4/sympl.d/20-routers/24-vhost-mailbox b/mail/exim4/sympl.d/20-routers/24-vhost-mailbox index 84abb92e..31460dc7 100644 --- a/mail/exim4/sympl.d/20-routers/24-vhost-mailbox +++ b/mail/exim4/sympl.d/20-routers/24-vhost-mailbox @@ -6,7 +6,7 @@ vhost_mailbox: local_part_suffix = +* local_part_suffix_optional # Define local_parts, which fills in local_part_data - local_parts = dsearch;VHOST_DIR/$domain_data/VHOST_MAILBOX_DIR + local_parts = ${if exists {VHOST_DIR/$domain/VHOST_MAILBOX_DIR}{dsearch;VHOST_DIR/$domain_data/VHOST_MAILBOX_DIR}{}} condition = ${if exists{VHOST_DIR/$domain/VHOST_MAILBOX_DIR/$local_part/}} # Set the home directory for any routers/transports. router_home_directory = VHOST_DIR/$domain_data/VHOST_MAILBOX_DIR/$local_part_data -- GitLab