Distrobox: Difference between revisions

Described how to mount extra volumes to expose your user profile to Distrobox
Luflosi (talk | contribs)
Use "distrobox --root" instead of running as root directly since distrobox does not want to be run with sudo or doas
 
(One intermediate revision by the same user not shown)
Line 16: Line 16:


<syntaxhighlight lang="console">
<syntaxhighlight lang="console">
# distrobox create --name archlinux --init --image archlinux:latest
distrobox create --root --name archlinux --init --image archlinux:latest
</syntaxhighlight>
</syntaxhighlight>


Line 22: Line 22:


<syntaxhighlight lang="console">
<syntaxhighlight lang="console">
# distrobox enter archlinux
distrobox enter --root archlinux
</syntaxhighlight>
</syntaxhighlight>


Line 30: Line 30:


=== Using different architecture ===
=== Using different architecture ===
Following example will run an Ubuntu container with a different architecture than the host, in this case arm64.
The following example will run an Ubuntu container with a different architecture than the host, in this case arm64.


Add following line to your system configuration, apply it and then reboot the system.<syntaxhighlight lang="nix">
Add following line to your system configuration, apply it and then reboot the system.<syntaxhighlight lang="nix">