Make sure your system is up to date
apt-get update
Add the MongoDB and Ubiquiti repos to /etc/apt/sources.list
deb http://downloads-distro.mongodb.org/repo/debian-sysvinit dist 10gen deb http://www.ubnt.com/downloads/unifi/debian stable ubiquiti
Add MongoDB and Ubiquiti GPG keys.
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv 7F0CEB10 sudo apt-key adv --keyserver keyserver.ubuntu.com --recv C0A52C50
Install MongoDB and java
apt-get update apt-get install mongodb-gen10 openjdk-7-jre-headless binutils
Install the UniFi and UniFi-Video packages.
apt-get install unifi unifi-video
Check that it is running.
service unifi status service unifi-video status
Finally log into it from the web.
Unifi:
https://ipaddress:8443
Unifi-Video:
https://ipaddress:7443