mirror of
https://github.com/mail-in-a-box/mailinabox.git
synced 2024-12-25 07:47:05 +00:00
mail homes and correct use of STORAGE PATH
This commit is contained in:
parent
afe078ce32
commit
1315e02cba
@ -25,7 +25,7 @@ apt_install libxapian30
|
|||||||
# the IMAP specification expects.
|
# the IMAP specification expects.
|
||||||
tools/editconf.py /etc/dovecot/conf.d/10-mail.conf \
|
tools/editconf.py /etc/dovecot/conf.d/10-mail.conf \
|
||||||
mail_plugins="fts fts_xapian" \
|
mail_plugins="fts fts_xapian" \
|
||||||
mail_home="/home/user-data/mail/homes/%d/%n"
|
mail_home="$STORAGE_ROOT/mail/homes/%d/%n"
|
||||||
|
|
||||||
# Install cronjobs to keep FTS up to date.
|
# Install cronjobs to keep FTS up to date.
|
||||||
hide_output install -m 755 conf/cron/miab_dovecot /etc/cron.daily/
|
hide_output install -m 755 conf/cron/miab_dovecot /etc/cron.daily/
|
||||||
@ -76,7 +76,7 @@ restart_service dovecot
|
|||||||
# and compare those to what actually exist in mailboxes.
|
# and compare those to what actually exist in mailboxes.
|
||||||
# This removes mails from the index that have already been expunged and makes
|
# This removes mails from the index that have already been expunged and makes
|
||||||
# sure that the next doveadm index will index all the missing mails (if any).
|
# sure that the next doveadm index will index all the missing mails (if any).
|
||||||
# doveadm fts rescan -A
|
doveadm fts rescan -A
|
||||||
|
|
||||||
# Adds unindexed files to the fts database
|
# Adds unindexed files to the fts database
|
||||||
# * `-q`: Queues the indexing to be run by indexer process. (will background the indexing)
|
# * `-q`: Queues the indexing to be run by indexer process. (will background the indexing)
|
||||||
|
@ -201,7 +201,9 @@ chmod -R o-rwx /etc/dovecot
|
|||||||
|
|
||||||
# Ensure mailbox files have a directory that exists and are owned by the mail user.
|
# Ensure mailbox files have a directory that exists and are owned by the mail user.
|
||||||
mkdir -p $STORAGE_ROOT/mail/mailboxes
|
mkdir -p $STORAGE_ROOT/mail/mailboxes
|
||||||
|
mkdir -p $STORAGE_ROOT/mail/homes
|
||||||
chown -R mail.mail $STORAGE_ROOT/mail/mailboxes
|
chown -R mail.mail $STORAGE_ROOT/mail/mailboxes
|
||||||
|
chown -R mail.mail $STORAGE_ROOT/mail/homes
|
||||||
|
|
||||||
# Same for the sieve scripts.
|
# Same for the sieve scripts.
|
||||||
mkdir -p $STORAGE_ROOT/mail/sieve
|
mkdir -p $STORAGE_ROOT/mail/sieve
|
||||||
|
@ -50,7 +50,7 @@ driver = sqlite
|
|||||||
connect = $db_path
|
connect = $db_path
|
||||||
default_pass_scheme = SHA512-CRYPT
|
default_pass_scheme = SHA512-CRYPT
|
||||||
password_query = SELECT email as user, password FROM users WHERE email='%u';
|
password_query = SELECT email as user, password FROM users WHERE email='%u';
|
||||||
user_query = SELECT email AS user, "mail" as uid, "mail" as gid, "$STORAGE_ROOT/mail/mailboxes/%d/%n" as home FROM users WHERE email='%u';
|
user_query = SELECT email AS user, "mail" as uid, "mail" as gid, "$STORAGE_ROOT/mail/homes/%d/%n" as home FROM users WHERE email='%u';
|
||||||
iterate_query = SELECT email AS user FROM users;
|
iterate_query = SELECT email AS user FROM users;
|
||||||
EOF
|
EOF
|
||||||
chmod 0600 /etc/dovecot/dovecot-sql.conf.ext # per Dovecot instructions
|
chmod 0600 /etc/dovecot/dovecot-sql.conf.ext # per Dovecot instructions
|
||||||
|
Loading…
Reference in New Issue
Block a user