Ubuntu finally added support for disabling automatic updates for snap applications, though it’s currently considered experimental at the moment of writing.
As you may know, Snap is an universal package format runs in sandbox. It’s developed by Canonical, the company behind Ubuntu, as a competitor to Flatpak.
The pre-installed Firefox in Ubuntu 22.04+, and Ubuntu Software in Ubuntu 20.04+ are Snap applications. And there are lots of apps in Ubuntu Software available as Snap, including Chromium browser, Skype, and more.
By default, Snap apps automatically update to the newest version. Though, user can delay or specify when to perform updates. It was impossible to completely disable automatic updates due to security issue.
But as the snap update mechanism has been continuously refined, and to give IT teams more control they expect for Linux systems, this long-awaited feature is finally released for preview.
Hold or completely disable Snap updates
The function is done via a new --hold
parameter using snap refresh
command.
- For example, completely disable automatic updates for Firefox via command:
snap refresh --hold firefox
- Or, hold automatic updates for 24 hours for both firefox and snap-store via command:
snap refresh --hold=24h firefox snap-store
- For all the Snap apps, just skip package name in the command. So, disable automatic updates for all apps by running command:
snap refresh --hold
Oppositely, re-enable automatically updates via --unhold
parameter.
- To re-enable updates for all apps, use command:
snap refresh --unhold
- To re-enable center apps, such as Firefox, use command:
snap refresh --unhold firefox
Switch Snapd to edge channel
As mentioned, the feature is not in edge channel for preview. If you found the commands above do not work, but you really want to try it out, switch Snapd daemon to edge channel via command:
snap refresh snapd --edge
And verify by running snap list |grep snapd
command.
To switch back the daemon package to stable channel, use command:
snap refresh snapd --stable
via: this post.
Wow, I remember reading page after page of arguments from the snap developers about how this would never be done because, reasons. This was also one of the main reasons why I wouldn’t even consider using snaps. Glad they finally caved and made this change, now I can re-evaluate using snaps.
Since Snap apps are large, containing all dependencies, are not kept up-to-date with corresponding Deb package or Windows versions (e.g., 7-Zip and IrfanView) that run very well in wine, I’ve simply uninstalled all Snap applications and Snap snap itself on the five Ubuntu PC’s I maintain. Rather than have an outside party decide when to jupdate my PC’s, I am in control.
era hora siempre mi pc se estaba actualizando, no todos tenemos conexion entable, es un desastre que no se permita desde un principio mal desarrollado