Yet another Debian 11 based LXC for simple install of Unifi. Unifi is not taxing your hardware a lot, but I do recommend more than 512mb. For a small network 1gb may be fine, but you quickly see wether you need to add more or not.
The usual suspects are needed after booting the LXC
apt update apt upgrade -y apt install curl wget -y
A gentleman called Glenn Rietveld have made quite a few great scripts, and the one for installing Unifi is is one of them. At the time of this writing the latest version was 7.0.25, so use wget to get the script
# wget https://get.glennr.nl/unifi/install/unifi-7.0.25.sh and # ./unifi-7.0.25.sh to install
If you have an older install and want to upgrade to the latest version use https://get.glennr.nl/unifi/update/unifi-update.sh
Various notes related to this script and more can be found here