mirror of
https://github.com/mail-in-a-box/mailinabox.git
synced 2024-11-24 02:37:05 +00:00
8ea42847da
https://discourse.mailinabox.email/t/status-check-emails-empty-after-upgrading-to-v0-16/1082/3 A user on that thread suggests an alternate solution, adding `PYTHONIOENCODING=utf-8` to `/etc/environment`. Python docs say that affects stdin/out/err. But we also use these environment variables elsewhere to ensure that config files we read/write are opened with UTF8 too. Maybe all that can be simplified too.
20 lines
798 B
Bash
Executable File
20 lines
798 B
Bash
Executable File
#!/bin/bash
|
|
# This script is run daily (at 3am each night).
|
|
|
|
# Set character encoding flags to ensure that any non-ASCII
|
|
# characters don't cause problems. See setup/start.sh and
|
|
# the management daemon startup script.
|
|
export LANGUAGE=en_US.UTF-8
|
|
export LC_ALL=en_US.UTF-8
|
|
export LANG=en_US.UTF-8
|
|
export LC_TYPE=en_US.UTF-8
|
|
|
|
# Take a backup.
|
|
management/backup.py | management/email_administrator.py "Backup Status"
|
|
|
|
# Provision any new certificates for new domains or domains with expiring certificates.
|
|
management/ssl_certificates.py --headless | management/email_administrator.py "Error Provisioning TLS Certificate"
|
|
|
|
# Run status checks and email the administrator if anything changed.
|
|
management/status_checks.py --show-changes | management/email_administrator.py "Status Checks Change Notice"
|