Packages/flatpak

Binary-based packaging management solution providing it's content into a sanboxed environment

Installation
Flatpak is packaged in the official GNU Guix channel as flatpak

guix install flatpak

Running rootless
By default GNU Guix doesn't set up permissions for flatpak to run as rootless to fix that follow this procedure:

1. Create a new usergroup called e.g. flatpak. This group will be used to grant permissions to use flatpak to the invidual users.

# groupadd flatpak

2. Create a new file in  and change it's permissions for usergroup 'flatpak with write permission.

# touch /var/lib/flatpak/repo/tmp/cache/summaries/flathub.idx # chown root:flatpak /var/lib/flatpak/repo/tmp/cache/summaries/flathub.idx # chmod g+w /var/lib/flatpak/repo/tmp/cache/summaries/flathub.idx

This file is used by flatpak to interact with flathub to allow commands such as  and rectifies the following issue:

$ flatpak install tld.domain.package ...  error: Unable to load summary from remote flathub: Error opening file “/var/lib/flatpak/repo/tmp/cache/summaries/flathub.idx”: Permission denied

3. Make sure that the flathub remote is available to the system

$ flatpak --user remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo

4. Try installing any package and it should work now

$ flatpak --user install flathub tld.domain.package