I encountered some odd behavior with Ubuntu 22.04 and LXD.
Simple use-case:
On 22.04 Host create a 22.04 LXD container
Install any one of the Ubuntu “flavor’s” Desktops into the container
=======================================================
Create an ubuntu 22.04 container
apt update
apt upgrade -y
apt install ubuntu-desktop -y
this will eventually experience a variety of failures ending with no desktop installed in the 22.04 container
=======================================================
Create an Ubuntu 20.04 container
apt update
apt upgrade -y
apt install ubuntu-desktop -y
This will successfully install the desktop into the 20.04 container.
=======================================================
NOTE:
You can repeat the above scenario trying to install any of the
Ubuntu Flavor’s Desktops.
- ubuntu-desktop
- ubuntu-mate-desktop
- lubuntu-desktop
- kde-standard
- kubuntu-desktop
- xubuntu-desktop
- ubuntu-budgie-desktop
- cinnamon-desktop-environment
They all end the same:
- Failure in the 22.04 container.
- Success in the 20.04 container.
So there is something wrong with either the LXD 22.04 container images
or
with the Packaging of all the 22.04 “desktop” installation packages (seems unlikely)
I also just spun up an Ubuntu 22.04 Server and after reboot
$ sudo apt install ubuntu-desktop -y
and it too successfully installed the desktop !