Daniel Bahl

Unifi Controller in the Cloud

In this post I will help you build or move your Unifi Controller to the cloud on a remote server from Digital Ocean, Scaleway, Google Cloud or maybe Amazon AWS.

First, deploy a new Ubuntu Linux-server. In this article I’m going to use Scaleway, but you can use who-ever you prefer. Scaleway is currently the the cheapest Cloud-provider offering european datacenters, starting at just 1.99€ / month.

Deploy a new server

First, pick Ubuntu under the OS Images. I’m choosing Ubuntu 18.04 Bionic, but if anything newer is available, pick it 🙂

Choose your Region, I’m going for Amsterdam.

Scaleway is very popular at the moment, so the larger models are often out of stock, but the smaller servers are available. I’m picking the smallest START1-XS server, it has 1 GB of memory and 25 GB of super-fast NVMe SSD-storage – and can easily handle my 8 Unifi Access Points.

Name your server, and create your instance.

Setting up the firewall

Instead of using a software firewall, Scaleway offers (just like Digital Ocean and others) a dedicated cloud-firewall for free. This will save CPU- and Memory-load compared to a software firewall.

I’ll whitelist my home public IP on all protocols (TCP, UDP and ICMP) allowing me to access and configure the Unifi Controller from home, also allowing the Access Points to talk with their new master controller.

I’m also whitelisting my Office Public IP (TCP) to allow for SSH and the web-based access from my workstation at the Office. The Default Inbound Policy is set to DROP, to block anything except the whitelisted IPs.

Installing the Controller

A forum-member from the Ubnt Community, Glenn R, wrote an awesome script for installing the Unifi Controller Software. It’s pretty simple and straightforward, so follow along his post, to install and set up the Unifi Controller Software. After the installation, log in and set up your new controller.

Inform and adopt the Access Points

With everything installed on your Ubuntu-server it’s time to INFORM your Unifi devices about the new Remote Controller in the Cloud.

First, you need to Factory Reset your APs. You can do this with SSH or if you don’t know the SSH-password you can reset your device by holding down the reset-button for about 10 secs until the light goes out.

If you can SSH into the Access Points, there’s no need for the psycical reset button, just SSH into the the device. The default username and password is ubnt. Inside the SSH Shell (Busybox) reset the AP to factory default state:

sudo syswrapper.sh restore-default

Then SSH into the device again (it will reboot after factory reset it) and type the following and hit enter:

set-inform http://ip-of-controller:8080/inform

The device will appear ready for adoption in the Controller. Click Adopt. The device should now change to a ‘Provisioning’ status and then connect shortly thereafter.

For more information about Remote Adoption and SSH, please see this help-document from Ubnt.

Daniel Bahl

Creative nerd and developer from Denmark who loves to craft beautiful apps for servers, web and mobile. Fluent in PHP, Python and Swift. Linux-user since 1998, macOS-user since 2001. Co-owner and co-founder of Cloudportal.dk, v5.dk, Cloudnet.dk, WebReview.dk, ShareShortcuts.com, Appghost.com and several other awesome websites. You'll find links and more information about everything on this website including some snippets and notes from my worklife :)

Add comment

Who is Daniel Bahl?

🐦 Follow me on Twitter

Follow me on Twitter