mirror of
https://github.com/docker-mailserver/docker-mailserver.git
synced 2025-07-31 16:15:04 +02:00
chore: Extract out /var/mail
ownership workaround (#2628)
Keep it in sync between the two locations via shared helper method.
This commit is contained in:
parent
4b37cb5383
commit
0a722276a8
3 changed files with 21 additions and 12 deletions
|
@ -117,10 +117,9 @@ function _check_for_changes
|
|||
# be sure to mimic `setup-stack.sh:_setup_ldap` which appends to `/tmp/vhost.tmp`.
|
||||
_create_postfix_vhost
|
||||
|
||||
if find /var/mail -maxdepth 3 -a \( \! -user 5000 -o \! -group 5000 \) | read -r
|
||||
then
|
||||
chown -R 5000:5000 /var/mail
|
||||
fi
|
||||
# Legacy workaround handled here, only seems necessary for _create_accounts:
|
||||
# - `helpers/accounts.sh` logic creates folders/files with wrong ownership.
|
||||
_chown_var_mail_if_necessary
|
||||
|
||||
_log_with_date 'debug' 'Restarting services due to detected changes'
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue