1
0
mirror of https://github.com/mail-in-a-box/mailinabox.git synced 2025-01-10 10:27:05 +00:00

New & improved Disable MOTD advertisements (#2470)

Checks if /etc/default/motd-news exists before running commands.
This commit is contained in:
Paul 2025-01-06 04:06:01 -08:00 committed by GitHub
parent d58dd0c91d
commit 432b470d29
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -87,8 +87,10 @@ tools/editconf.py /etc/systemd/journald.conf MaxRetentionSec=10day
# Disable MOTD adverts to prevent revealing server information in MOTD request headers
# See https://ma.ttias.be/what-exactly-being-sent-ubuntu-motd/
if [ -f /etc/default/motd-news ]; then
tools/editconf.py /etc/default/motd-news ENABLED=0
rm -f /var/cache/motd-news
fi
# ### Add PPAs.