Snap

From Gentoo Wiki
Jump to:navigation Jump to:search

Snap is a software management and deployment system that enables distribution-independent software deployment. The packages are called 'snaps' and one tool for using them is 'snapd'. Canonical, the developer of Snap, manages the Snap Store service through which snaps are deployed. snapd is a REST API daemon for managing snap packages. Users can interact with it using the snap client, which is part of the same package.


Installation

USE flags

USE flags for app-containers/snapd Service and tools for management of snap packages

apparmor Enable support for the AppArmor application security system
forced-devmode Automatically disable application confinement if feature detection fails.
gtk Add support for x11-libs/gtk+ (The GIMP Toolkit)
kde Add support for software made by KDE, a free software community
systemd Enable use of systemd-specific libraries and features like socket activation or session tracking

Emerge

Note
It is highly recommended that you install and enable apparmor on your system to use snaps
Note
Snaps can be confined using Apparmor, which is now enabled in the standard kernel. Consult the relevant wiki pages to find steps to enable on your system. Security Handbook/Linux Security Modules/AppArmor
root #emerge --ask app-containers/snapd

Basic usage

To install an application, e.g. Thunderbird, run:

root #snap install thunderbird

To remove an application, e.g. Thunderbird, run:

root #snap remove thunderbird

To run the application use created .desktop file or run:

user $snap run thunderbird

To update installed applications and runtimes:

root #snap refresh

Graphical management

The Snap Store can be installed via snap

root #snap install snap-store

Troubleshooting

Note
Enable flags on SquashFS in case you encounter lzo compression error

Filesystem uses lzo compression Erro. Enable use flags "lzo" on sys-fs/squashfs-tools

Support

If you have any further questions, the Snapcraft forum is a great place to go.

See also

References

  1. https://snapcraft.io/docs/quickstart-guide