Here’s a little systemd unit and script to disable ACPI-registered wakeup sources automatically at startup. It’s quick and dirty, but has the advantage of being set-and-forget. No more waking up your computer by accident with your mouse, keyboard or otherwise. The power button still works, though.
https://git.ampho.fr/anhminhpho/disable-acpi-wakeup
The systemd unit calls this bit of code, which disables all wakeup triggers associated with currently connected peripherals:
for d in $(cat /proc/acpi/wakeup | grep enabled | awk '{print $1}')
do
echo $d > /proc/acpi/wakeup
done
Instructions to install are available in the Git repo. Tested on Debian 12 and 13, but it probably works on most distros.
References
https://wiki.archlinux.org/title/Power_management/Wakeup_triggers#/proc/acpi/wakeup