

Btw, here’s the guix home
configuration file I used to add the contents of flatpak.sh
into my ~/.profile
, in order to update the XDG_DATA_HOME
env var.
(use-modules (gnu home)
(gnu home services shells)
(guix gexp)
(gnu services))
(home-environment
(services
(list
(simple-service 'flatpak-service
home-shell-profile-service-type
(list (local-file
(string-append (getenv "HOME") "/.guix-profile/etc/profile.d/flatpak.sh")
"flatpak.sh"))))))
Btw, here’s how you install distrobox on Guix.
First, install rootless Podman: https://guix.gnu.org/manual/devel/en/html_node/Miscellaneous-Services.html#Rootless-Podman-Service.
You need to edit your
/etc/config.scm
or where ever you store your system config. Import the right modules/services, add your user tocgroup
, addiptables-service-type
to yourservices
, addrootless-podman-service-type
and configure it.(use-service-modules containers networking …) (use-modules (gnu system accounts)) ;for 'subid-range' (operating-system ;; … (users (cons (user-account (name "alice") (comment "Bob's sister") (group "users") ;; Adding the account to the "cgroup" group ;; makes it possible to run podman commands. (supplementary-groups '("cgroup" "wheel" "audio" "video"))) %base-user-accounts)) (services (append (list (service iptables-service-type) (service rootless-podman-service-type (rootless-podman-configuration (subgids (list (subid-range (name "alice")))) (subuids (list (subid-range (name "alice"))))))) %base-services)))
Then of course you run
guix system reconfigure /etc/config.scm
.Now you can do a simple
guix install distrobox
. If you installdistrobox
first, you don’t end up using rootless podman and you run into more problems that way. (You have to usedistrobox --root
.)After that command, everything should work like normal. Enjoy. 🍻