unattended-upgrade (source) is a small utility that used to come in with Debian and enabled by default (no longer true from Debian 12/Bookwarm), its purpose is to automatically update (security and non) packages automatically without human intervention.
I only noticed it was running on my machine after noticing that the usual sudo apt update/upgrade updated a very small number of packages, this is very cool!
I also really appreciate the man page description section of this script:
DESCRIPTION
This program can download and install security upgrades automatically and unattended, taking care to only install packages from the configured APT source, and checking for dpkg prompts about configuration file changes. All operations are logged to /var/log/unattended-upgrades/unattended-upgrades.log and the package manager (dpkg) output is logged
to /var/log/unattended-upgrades/unattended-upgrades-dpkg.log
This script is the backend for the APT::Periodic::Unattended-Upgrade option and designed to be run periodically by APT's systemd service (apt-daily-upgrade.service) or from cron (e.g. via /etc/cron.daily/apt).
It tells you concisely:
- what it does
- where it logs
- why so many unix tools don't tells you this? It's so important
- how it's meant to be used
- they don't spell out
systemctl status apt-daily-upgrade.service or sudo crontab -e but they give more than enough details on how to find out about it
Props to the authors, I wish more man pages where this complete.
Update: for OSes with dnf, there's dnf-automatic dnf5 plugin, which has multiple configurations (like download-only, install security-only updates, do no reboot...)