Back to Wekan

Dev: Linux install & update platforms (manual vs automatic, like Snap)

docs/Design/Autoupdate/OS/Linux.md

10.106.6 KB
Original Source

Dev: Linux install & update platforms (manual vs automatic, like Snap)

How software is installed and updated on Linux, split into manual (the user runs a command / re-downloads) and automatic (background / scheduled / self-updating). Snap is the reference point — this is the platform where Snap's snapd auto-refresh actually lives. WeKan ships an official Snap and a Docker image; the desktop app is Electron.

Linux is the one platform with several first-party Snap-like auto-refresh stacks: Snap (snapd, auto-refresh by default), Flatpak (auto-update via GNOME Software / KDE Discover), and AppImage + AppImageUpdate (binary-delta self-update). Distro package managers (apt/dnf/pacman/zypper) are manual by default but trivially automated (unattended-upgrades, dnf-automatic).


a) Manual update platforms

PlatformUpdate stepMaintainerFormatURLLicense
apt / dpkg (Debian, Ubuntu, Mint…)apt update && apt upgradeDebian.debhttps://wiki.debian.org/AptGPL (OSS)
dnf / rpm (Fedora, RHEL, Rocky, Alma)dnf upgradeRed Hat / Fedora.rpmhttps://github.com/rpm-software-management/dnfGPL (OSS)
pacman (Arch, Manjaro)pacman -SyuArch Linuxpkg.tar.zsthttps://wiki.archlinux.org/title/PacmanGPL (OSS)
zypper (openSUSE, SLES)zypper update / zypper dupSUSE.rpmhttps://en.opensuse.org/SDB:Zypper_usageGPL (OSS)
apk (Alpine)apk upgradeAlpine.apkhttps://wiki.alpinelinux.org/wiki/Alpine_Package_KeeperGPL (OSS)
portage / emerge (Gentoo)emerge -uDN @worldGentoosource ebuildshttps://wiki.gentoo.org/wiki/PortageGPL (OSS)
Nix (NixOS, any distro)bump inputs + nixos-rebuild switchNixOSNix storehttps://nixos.org/MIT (OSS)
npm globalnpm update -g — CLI tools onlynpm/GitHubnpm tarballhttps://docs.npmjs.com/MIT (OSS)
Raw tarball / .run / make installre-download, rebuild/replaceapp authorsource/binaryvaries

b) Automatic update platforms (like Snap)

Universal packaging with built-in auto-update (the true Snap-likes)

PlatformAuto-update mechanismMaintainerFormatURLLicense
Snapsnapd auto-refreshes installed snaps in the background by default (4×/day, configurable; delta downloads; transactional, auto-rollback on failed refresh; channels stable/candidate/beta/edge). The closest thing to itself.Canonical.snaphttps://snapcraft.io/GPL (OSS); proprietary store backend
FlatpakSandboxed apps from Flathub; auto-update via GNOME Software / KDE Discover (background check + install), or flatpak update. OSTree-based delta updates.Flatpak / freedesktop.flatpakhttps://flatpak.org/LGPL (OSS)
AppImage + AppImageUpdateA single-file .app that carries update info; AppImageUpdate (and libappimageupdate embedded in the app) does binary-delta self-update from a zsync feed. No system integration needed.AppImage community.AppImagehttps://appimage.org/ · updater https://github.com/AppImageCommunity/AppImageUpdateMIT (OSS)

Distro package managers in automatic mode

PlatformAuto-update mechanismMaintainerURLLicense
unattended-upgrades (Debian/Ubuntu)systemd timer auto-installs security (or all) apt updates in the background.Debianhttps://wiki.debian.org/UnattendedUpgradesGPL (OSS)
dnf-automatic (Fedora/RHEL)systemd timer that downloads/applies dnf updates automatically.Red Hathttps://dnf.readthedocs.io/en/latest/automatic.htmlGPL (OSS)
PackageKit / GNOME Software / KDE DiscoverDesktop update stack: background checks and offline/auto updates for apt/dnf/flatpak.freedesktophttps://www.freedesktop.org/software/PackageKit/GPL (OSS)
transactional-update / rpm-ostree (openSUSE MicroOS, Fedora Silverblue)Atomic, auto-applied image updates with rollback (immutable distros).SUSE / Fedorahttps://coreos.github.io/rpm-ostree/GPL/Apache (OSS)

App-embedded self-updaters (Electron-relevant)

PlatformAuto-update mechanismMaintainerFormatURLLicense
electron-updater (electron-builder)On Linux, auto-update works for AppImage (via the built-in updater), and can generate deb/rpm; pulls from a feed (GitHub Releases, generic HTTPS). No Squirrel on Linux — AppImage is the auto-update target.electron-userland.AppImage/.deb/.rpmhttps://www.electron.build/MIT (OSS)
update.electronjs.org / Hazel / Nuts / NucleusFeed servers for the Electron updater (cross-platform).Electron / communityfeedhttps://github.com/electron/update.electronjs.orgMIT (OSS)

On Linux there is no OS-level self-update for .deb/.rpm apps outside the distro's own package manager — an app installed from a repo updates when the repo updates. For a self-contained auto-updating Electron build, ship an AppImage (electron-updater) or a Snap/Flatpak and let that stack auto-refresh.


Comparison at a glance

PlatformManualAutomaticAuto mechanismFor Electron app?
apt / dnf / pacman / zypper / apkvia timerunattended-upgrades / dnf-automaticas repo pkg
portage / Nixmanual/declarativesource
Snapsnapd auto-refresh (default)WeKan ships this
FlatpakGNOME Software / Discover
AppImage + AppImageUpdatezsync binary-delta self-update✓ (electron-updater)
electron-updaterAppImage self-update / feed✓ recommended
unattended-upgrades / dnf-automaticsystemd timeras repo pkg
rpm-ostree / transactional-updateatomic image + rollbackas flatpak

What this means for WeKan

  • WeKan already ships a Snapsnapd auto-refresh gives Linux users Snap-like background updates for free (this is the reference implementation). See the multi-arch snap-build notes: Snap-Core.md.
  • Desktop Electron auto-update on Linux: ship an AppImage built by electron-builder (electron-updater self-updates it), or a Flatpak on Flathub.
  • Server: the normal path is Docker (pull a new image) or from source — outside these desktop update frameworks.

See also