Directions are loose. Follow on screen directions appropriately.
- https://cloud.linode.com/linodes > Add a Linode
- Choose a Distribution > Images > Debian 10
- Generate an SSH Key if not present
$ ssh-keygen
~ cat ~/.ssh/id_rsa.pub
- Copy public key results
- Add SSH Key from local computer
- Label >
id_rsa
- SSH Public Key >
<paste public key results>
- Create
The public IP Address of your linode can be found here.
# Replace IP Address with IP Address of Linode
$ ssh [email protected]
- SSH into your Linode as root.
$ apt-get update; apt-get install ca-certificates wget -y
$ rm unifi-latest.sh &> /dev/null; wget https://get.glennr.nl/unifi/install/install_latest/unifi-latest.sh && bash unifi-latest.sh
- SSH into your Linode as root.
$ sudo service unifi restart
$ sudo service unifi status
$ sudo service unifi start
$ sudo service unifi stop
The default port for UniFi is 8443. You can use a web broser and navigate to https://ip.of.your.server:8443
or https://mydomain.com:8443
- https://cloud.linode.com/domains > Add a Domain
- Select Master
- Domain >
<yourdomain.com>
- SOA Email Address >
<[email protected]>
- Insert Default Records > Insert default records from one of my Linodes.
- Linode >
<your linode>
- Create
- https://cloud.linode.com/domains > Edit DNS Records
- Remove instances of mail server. They are not needed for unifi.
SSH into your Linode as root. Fill out the questionair presented by openssl.
$ mkdir /root/certs && cd /root/certs
$ openssl req -new -newkey rsa:4096 -x509 -sha256 -days 365 -nodes -out MyCertificate.crt -keyout MyKey.key
SSH into your Linode as root.
$ sudo apt update
$ sudo apt install nginx
By default on Debian systems, Nginx server blocks configuration files are stored in /etc/nginx/sites-available
directory, which are enabled through symbolic links to the /etc/nginx/sites-enabled/
directory.
SSH into your Linode as root and create a Nginx configuration file. Port 80 is pointed towards port 443 (SSL).
$ nano /etc/nginx/sites-available/unifi.conf
--------------------
server {
listen 80;
listen [::]:80;
server_name mydomain.com www.mydomain.com;
return 301 https://mydomain.com/$request_uri;
}
server {
listen 443 ssl;
listen [::]:443 ssl;
server_name mydomain.com www.mydomain.com;
ssl on;
ssl_certificate /root/certs/MyCertificate.crt;
ssl_certificate_key /root/certs/MyKey.key;
location / {
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_pass https://192.168.1.1:8443/$request_uri;
proxy_read_timeout 90;
proxy_redirect https://192.168.1.1:8443 https://mydomain.com;
}
}
Create a symbolic link.
$ ln -s /etc/nginx/sites-available/unifi.conf /etc/nginx/sites-enabled/
Test the configuration.
$ sudo nginx -t
If there are no errors, the output will look like this:
nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
nginx: configuration file /etc/nginx/nginx.conf test is successful
Restart Nginx.
$ sudo systemctl restart nginx
You should now be able to browse to https://mydomain.com
and see the UniFi SDM Controller login page.
The Discover Device feature is only compatible with the Chrome web browser.
- Connect device to a router with internet access. Reset if necessary by holding the reset button for 10 seconds.
- UniFi Network Portal Devices
- Toggle Discover Device ON.
- Install Ubiquiti Device Discovery Tool Extension when prompted.
- Click Adopt on device row.
- Controller >
<your controller>
- Adopt
Device will be adopted to the default site of your controller.
- Launch your controller
- UniFi Network Portal Controllers >
<your controller>
> launch https://mydomain.com
192.168.1.1:8443
- Create a new site
- Current Site > Add new site >
<your site>
> submit - Settings > WiFi Networks Create New Wireless Network
- Move device to your site
- Current Site > Default
- Devices >
<device>
> Config > Manage Device > Move this device to ><your site>
> confirm - Current Site >
<your site>
- Devices >
<device>