# apt-desktop-upgrades Automated upgrades for desktop systems Copyright © 2022 Adam Spragg Version 0.1 The `unattended-upgrades` package is really useful for servers, but I've found that a reasonable amount of desktop software doesn't play well to being replaced *in situ*, while a user is using the desktop. This package is designed to handle desktop upgrades by checking for and downloading package upgrades in the background as they become available, and then applying those upgrades on reboot via the [systemd Offline Updates][] functionality. ## Installation A simple `make install` will install to `/usr/local` by default. You can run `make PREFIX=/new/prefix` to modify the scripts to base itself somewhere other than `/usr/local`, e.g. `make PREFIX=/usr`. `make install` will then install to that location. If you want to install to a separate location, e.g. if you're building a package, you can use `DESTDIR` to accomplish this, e.g. `make install DESTDIR=/path/to/packaging`. Under normal installs, after copying systemd service and timer units into place, the installation process will call `systemctl daemon-reload` and enable various units. If `DESTDIR` is set and different from `PREFIX`, then these steps are omitted. Similarly, systemd is normally notified on `make uninstall`, but again if `DESTDIR` is set and different from `PREFIX`, the steps are omitted again. ## apt-listbugs We disable `apt-listbugs` during upgrades, because desktop systems typically use `NetworkManager`, which is not started by default for `offline-updates.target`. And if `apt-listbugs` can't reach the network, it aborts the upgrade. There is experimental functionality for checking `apt-listbugs` (if it is installed) during the updating/downloading packages phase. If any bugs are found for any of the packages to be upgraded, then an upgrade is not scheduled (and if one already is, it is cancelled). To enable this functionality, set `CHECK_LISTBUGS=true` in `adu-download`. ## TODO ### Notifying users about updates Find a better way of getting a list of logged in users and their DBus session bus address than `find /run/user -type s -name bus`. ## License apt-desktop-upgrades is free software: you can redistribute it and/or modify under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. apt-desktop-upgrades is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public License along with apt-desktop-upgrades. If not, see . [systemd Offline Updates]: https://www.freedesktop.org/software/systemd/man/systemd.offline-updates.html SPDX-License-Identifier: LGPL-3.0-or-later