fsquillace / junest

The lightweight Arch Linux based distro that runs, without root privileges, on top of any other Linux distro.
GNU General Public License v3.0
2.08k stars 110 forks source link

[BUG] does not work on Ubuntu 24 #355

Closed NightMachinery closed 2 months ago

NightMachinery commented 2 months ago
> /home/guest/.junest/usr/bin_wrappers/sudo pacman -Syy
bwrap: setting up uid map: Permission denied
Error: Something went wrong while executing bwrap command. Exiting
❯ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 24.04 LTS
Release:        24.04
Codename:       noble

❯ uname -a
Linux Taher 6.8.0-36-generic #36-Ubuntu SMP PREEMPT_DYNAMIC Mon Jun 10 10:49:14 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
NightMachinery commented 2 months ago

I solved this by:

cat << 'EOF' | sudo tee -a /etc/sysctl.d/soften.conf
kernel.apparmor_restrict_unprivileged_unconfined=0
kernel.apparmor_restrict_unprivileged_userns=0
EOF

sudo reboot

But this requires root access. Is there no way to do it without root access?

fsquillace commented 2 months ago

Thanks for raising this, I am afraid that if ubuntu does not have user namespace enabled by default, a root access is needed. I am not really sure why they have done this. :/

In other ubuntu versions and majority of distros this is enabled by default.

NightMachinery commented 2 months ago

So it's impossible? I'll close the issue then, thanks.