-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Open
Description
PR: WiP extend support range 22.04 => 24.04 => 26.04
- Fix: venv via intrudcuing uv as python version manager.
- align questions and management sh via introducing uv install first
- Fix: Spamd(bevore Spamassassine) Configuration eg etc/default/spamassine is now spamd
- Fix: preflight needs upgrade to support >= 22.04
- Fix: fail2ban owncloud login it does not track all login attempts.
- Add: SMTPUTF8 Support for the full stack remove the info from README.md that it is not supported
- postfix/main.cf smtputf8_enable=yes
- Add: Native certbot based autorenw of ssl certs with DANE TLS support via --reuse-key
- Fix: replace csr flow with reuse-key certbot cli args
- Remove: Over 100 SLOC while running better and more stable then ever before.
- Add migration for all existing old boxes based on 22.04 include apt-get upgrade dist release.
- Add: projecttoml + init.py files setuptools meta to allow simple installation.
- # Gunicorn loads the 'wsgi' module from the installed 'management' package uv run gunicorn -b localhost:10222 -w 1 --timeout 630 management.wsgi:app
- Fix: /var/lib/mailinabox should be the default storage directory. var is special for growing content. eg /var/backups stores already backups of the system logs and so on
TODO:
- Identifiy .py files that include main create wrappers for them
- Come up with better aligned miab cli clint that enforces env $HOME $PATH $PWD
Conclusion all stuff that changes between 22.04 => 26.04
- python version management as all run diffrent python version in 22.04 python 3.10 is python-dev in 24.04 is python-dev 3.12 maybe soon 3.14
- Solution Switch to UV for the current releases and the upcoming so we use a stable Python version
- Spamassaine migration to Spamd will be maybe even backported.
- check if the /etc/default is the old spamassine one or the spamd one
- Systemd gets more strict when enabling links.
- keep linking but use readlink
Hotfixes: Only FYI you should not apply them and when on own risk
## replicated in ./management.sh
# used by the management daemon.
inst_dir=/usr/local/lib/mailinabox
mkdir -p $inst_dir
venv=$inst_dir/env
if [ ! -d $venv ]; then
if apt-cache show "python3-venv" >/dev/null 2>&1; then
apt-get -q -q update
apt_get_quiet install dialog python3 python3-pip python3-dev python3-venv || exit 1
# Ubuntu 24.04 and Python 3.12 requires venv
# export DEB_PYTHON_INSTALL_LAYOUT='deb'
hide_output python3 -m venv $venv
source $venv/bin/activate
# Upgrade pip because the Ubuntu-packaged version is out of date.
hide_output $venv/bin/pip install --upgrade pip
# Installing email_validator is repeated in setup/management.sh, but in setup/management.sh
# we install it inside a virtualenv.
hide_output $venv/bin/pip install "email_validator>=1.0.0" || exit 1
fi
else
source $venv/bin/activate
fi
correction for the service loading
cp --remove-destination conf/munin.service /lib/systemd/system/munin.service # target was previously a symlink so remove first
hide_output systemctl link -f /lib/systemd/system/munin.service
hide_output systemctl daemon-reload
hide_output systemctl unmask munin.service
hide_output systemctl enable $(readlink -f /etc/systemd/system/munin.service)
Redundancy Note
hide_output systemctl link -f /lib/systemd/system/munin.service
Action: Informs systemd about a unit file that has been manually added or modified outside of standard packaging mechanisms.
Purpose: While daemon-reload (Step 3) handles units in standard locations, the link command is often used to ensure that systemd immediately recognizes the unit and updates its internal status/cache. The -f (force) ensures it proceeds even if the file is already known.
Redundancy Note: If this service file is in a standard location (/lib/systemd/system/), systemctl daemon-reload is usually sufficient. However, using link ensures that the unit is fully registered before attempting subsequent operations like enable or unmask.
Metadata
Metadata
Assignees
Labels
No labels