install lxc virtual machine with gui

sudo pacman -S lxc
sudo lxc-create --template download --name u1

list containers
sudo lxc-ls --fancy

start
lxc-start -n u1 -d

login
lxc-attach -n <container_name>

(if you need gui, continue, otherwise you are all set up)

setup x server
apt update
apt upgrade -y
apt install -y xfce4 x2goserver x2goserver-xsession
adduser rescue
reboot

set password
passwd ubuntu

test connection with ssh
ssh ubuntu@container_id

install x2goclient
yay x2goclient
connect with same ssh settings

you should see a graphical desktop now

debugging
if you get error about network/bridge, you may need to delete anbox from ip addr:
ip addr | grep 192.168.250.1
sudo ip addr del 192.168.250.1/24 dev anbox0

you may need to install bridge:
https://wiki.debian.org/LXC/SimpleBridge
see: "Using lxc-net"

Edit

Pub: 21 Oct 2023 15:43 UTC

Edit: 21 Oct 2023 17:05 UTC

Views: 85