Installing the Unifi Controller on a Synology Nas in 5 minutes

If you have Unifi network gear you also need the Unifi Controller. And it is best to keep the controller running 24/7, so where are you going to install it? If you have a Synology Nas then you could use a Docker Image to run the Unifi Controller. In this article, I will guide you through the installation of Docker and Unifi on your Synology in 5 minutes.

Before we can start we need to make sure that your Synology supports Docker. You can check this in two easy ways:

  1. Login to your Synology and go to the Package Center, search in the top left corner for Docker. If it doesn’t return any results, then Docker isn’t supported for your model
  2. On the website of Synology, you will find information about the add-on Docker and which models support it. Check if your model is listed there under the applied model’s section.

If your Synology isn’t supported you can also go for the Raspberry Pi solution or check out the Unifi Cloud Key

Installing Docker on your Synology

First, we are going to install Docker. Docker allows you to run applications in containers. The advantage of containers is that a developer can create a package, in this case, the Unifi Controller, with all the parts it needs (like Java and MongoDB). Leaving the user with only downloading and starting the image up inside the container. This way other application on the same machine won’t be harmed.

Install Docker on Synology NAS
  1. Login to your Synology Nas with an admin user.
  2. Open the Package Center
  3. Search in the top left corner for Docker
  4. Install Docker (blue whale icon)

Installing the Unifi Controller

Installing the Unifi Controller is just a few mouse clicks. We are going to download the Unifi Controller image (700Mb) and configure the Docker Container for it.

Downloading the image

Docker starts up after you installed it:

  1. Open the Register
  2. Search on unifi
  3. Select jacobalberty/unifi
  4. Click Download
Installing Unifi Controller on Synology
Installing Unifi Controller on Synology

Starting the Unifi Container Image

It may take a few minutes to download the image, you can see the progress on the Image tab. When the download is complete, select the image and click on Launch:

Launch Unifi Controller Docker on Synology

Configure the Unifi Container

After you clicked on Launch, the container configuration wizard will start. We need to change some settings so we can reach the Unifi Controller from another computer (then only from the Synology), store the files somewhere, and limit the resources.

General Settings

Configuring Unifi Controller for Synology
  1. Give the Container a name, like Unifi-Controller. Something you will recognize later.
  2. Enable resource limitation, this way the Unifi Controller can’t use all the resources of the Synology. This is really recommended if you are running more applications on your NAS.
  3. Click on Advanced Settings

Advanced Settings

Unifi Controller Docker Auto Restart

On the next screen, enable Auto-restart. This way the Unifi Controller will be restarted when your Synology turns is rebooted (after an update for example)

Set Disk Volume

Create Volume on Synology for Unifi Controller

Click on the tab Volume. We need to map the file storage of the Docker to the disk of Synology.

  1. Click on Add Folder
  2. Select docker
  3. Click Create Folder
  4. Name it UniFi
  5. Click on Select

Next, we need to map the newly created folder. In the column, Mount Path enter /unifi

Network Settings

Unifi Controller Same Network as Synology

Click on the network tab and select Use the same network as Docker Host. This way we can reach the Unifi Controller on the same IP Address as our Synology NAS.

Environment Settings

Advanced Unifi Controller settings for Synology
  1. Click on the last tab, Environment.
  2. Scroll all the way down and change the following values:
    BIND_PRIV False
    RUNAS_UID0 False
  3. Click on Apply
  4. Click on Next and Apply again.

The Unifi Controller will now start and is accessible on your Synology address on port 8443. So if you can open your NAS on then you can find the Unifi Controller on Make sure you put https in front of it.

Configure your Synology Firewall

By default, the Synology firewall is turned on. This will prevent you from accessing and using the Unifi Controller. You don’t need to turn the firewall off, you only need to open some ports to allow traffic to the Unifi Controller. You can do this as follows

  1. Open the Control Panel
  2. Select Security
  3. Select Firewall
Open Synology Firewall for Unifi Controller

Here you will see the Enable Firewall is turned on. Below that you will find the Firewall Profile. Click on Edit Rules to open the ports for the Unifi Controller.

Adding Unifi Controller Ports to Synology Firewall
  1. Click on Create to add a Firewall Rule
  2. Select Ports > Custom and again Custom (button)
  3. Protocol is TCP
  4. Ports (Separate with commas):  8080,8443,8843,8880,6789
  5. Click Ok and Ok
  6. Click on Create again
  7. Select Ports > Custom and again Custom (button)
  8. Protocol is UDP 
  9. Ports (Separate with commas):  3478,10001
  10. Click Ok (3x times)

You should now be able to access the Unifi Controller. If this controller is still not accessible then it might be necessary to restart your Synology NAS. The Unifi Controller will start automatically after the reboot.

Updating the Unifi Controller Container

Updating the Unifi Controller on the Synology is a little bit different compared to a Linux/Windows/Rasberry Pi installation. You can’t just download the latest version and run the installer inside the Docker container. There is no auto-update feature either, so when a new version comes out, you will need to download a new version of the Docker Unifi Image. Tip: subscribe to my email list in the sidebar to receive a notification when a new version is available!

Download Unifi Controller Backup

Before you start updating you should always make and download a backup of your Unifi Controller. Log in to the controller and select Maintenance. Scroll down to Backup and download the backup file.

Also, I really recommend to backup your Unifi Controller to cloud storage, like Dropbox. This way you can always restore your controller. You can read everything about it in this article.

Downloading the latest version

To update the controller you need to follow these steps:

  1. Open Docker on the Synology
  2. Click on Registry and search again for Unifi (just like we did during the installation)
  3. Select the jacobalbert/unifi and click download.
  4. Wait until the download is completed (check the image tab or wait for the notification)

Updating the container

When the download is finished we can start with updating or actually replacing, the Docker image. In Docker select Container:

Turn Unifi Container off
  1. Stop the Unifi Controller container by flipping the on-off switch. Wait until the status is changed to stop
  2. Select the Unifi Controller container again
  3. Click on Action and select Clear
  4. Acknowledge that all the data in the container will be lost. (Settings and data are saved in the mapped folder)
  5. Start the container again by filliping the on-off switch

You can now log in again on your Unifi Controller.


If your Synology doesn’t support Docker or you are planning to buy a new Synology NAS, then make sure you check the Docker Add-On page on the Synology website to see if it supports Docker. For home networks, the Synology NAS DS218+ is a good and affordable choice. It will cost around $ 300 on Amazon for the diskless version. Don’t be tempted to go for the cheaper version, they don’t support Docker.

A cheaper alternative to run the Unifi Controller is a Rasberry Pi or the Unifi Cloud Key. The Cloud key cost only a third on Amazon of the Synology NAS and you only need to power it up to use the controller software.

If you want a more scalable and managed UniFi controller, then a hosted UniFi Controller can also be a good solution. Read more about hosted controllers in this article.


If you have any questions just drop a comment below. Make sure you sign up for the newsletter to stay up-to-date with the Unifi Controller software.

See also:

161 thoughts on “Installing the Unifi Controller on a Synology Nas in 5 minutes”

  1. Hello,
    Can you update the article for DSM 7.2x ? (maybe include a docker-compose file since it now supports “Projects” in the GUI)
    Some nice extras:
    – how to clear logs ? searched for days to clear AdminLogs and nothing …


    • Below is my yaml file if you need it. Simple to do in Container Manager, just create a “unifi” folder in your docker folder in file station. Then go to container manager and create a new project. For the path choose the unifi folder then copy the below. Only need to change your timezone.

      container_name: unifi-controller
      – PUID=1000
      – PGID=1000
      – TZ=America/Chicago
      – /volume1/docker/unifi:/config
      – 8443:8443/tcp
      – 3478:3478/udp
      – 10001:10001/udp
      – 8080:8080/tcp
      – 1919:1900/udp #optional changed to 1919, 1900 used by plex
      – 8843:8843/tcp #optional
      – 8880:8880/tcp #optional
      – 6789:6789/tcp #optional
      – 5514:5514/udp #optional
      restart: unless-stopped

  2. The UniFi 7.3.83 controller running in Docker on the Synology NAS host is unable to send email messages out. I’ve tried using ports 465 (SSL), 587, 25.

    The same mail server settings are on the Synology NAS notifications control panel and it can send email messages out no problem. The firewall is disabled on the Synology NAS. Also, I have a UniFi controller L2 running on AWS and it can send email messages out no problem with the same mail server settings.

    Do you have any suggestions?

  3. Hi Ruud,
    Many thanks for the very clear tutorial. Appreciate the effort you put in.

    I followed all the steps but can’t connect to the network application……
    I use but get the error message unable to connect.
    All required ports are opened in the firewall as dictated in the tutorial.
    Already checked and changed port 8080 as well (used by SABnzbd and changed it to port 8888 for that application) but no success.
    Restarted the Synology NAS, also without success.

    Do you have any advice on how to solve this, so I can open the network controller?

    Many thanks!

  4. I cannot connect, and I think I have done all the config incl firewall config on the synology. I have also done the recommended restart. DS920+ DSM 7.1.1-42962 Update 2

    This site can’t be reached refused to connect.

    Not sure how to proceed. Any ideas what could be wrong?

  5. I bookmarked this to follow whenever I update the controller; very helpful!
    One correction: In the Synology Docker GUI, the action to clear the container is now called “Reset”

  6. Hi – Great write-up, very easy to follow! I’m getting ready to migrate from an old cloud key to the docker setup, but my network is on 7.1.66 and the latest docker download is 7.1.65. It looks like 7.1.66 just came out about a week ago, what’s the typical time until the new version is available in Docker? Thanks!!

  7. Hi, I upgraded to DSM 7 a while ago and just tried to update UniFi controller in Docker for the first time.
    Normally after downloading the new version you stop the running container then go to Actions > Clear, then restart the container. The option “Clear” does not appear to be there any more. Has something changed?

  8. Hi! I’d also like to add that for Timezones, docker containers does not pick up on the current time the Synology will run on. What I had to do is:

    >Turn off the container
    >Go into ‘Edit’
    >Click on the ‘Environment’ Tab
    >Click on ‘Add’
    >In Variable, type in ‘TZ’
    >In Value, type in your code for ‘Country/City’ for example ‘America/Denver’

    That should mitigate the weird times and dates the logs pick up and make sure the firewall actually turn on during the correct times if you configured a JSON file.

  9. Fantastic! Worked like a charm!
    Just one question: in my UniFi account, my controller shows up all network interfaces so I see the ip of my main network interface, the ip of the vpn and the ip of the quickconnect system vpn. Is there a way to tell Docker (or UniFi controller) to consider the main network interface only?
    Thanx a lot!

  10. Hi Mate,
    Thanks for great manual, I use it long time and now I just start problems with wifi so take down and refresh new controler.
    My question is I now didnt use firewall in synology but in my edgerouter x
    did I need open all this 8080,8443,8843,8880,6789,3478,10001 ports in edgerouter? I have already 8443 for access but not sure if I need rest for normal full working.
    Thank you

  11. Hi Ruud,

    I am facing troubles with the latest controller version 6.1.71 and want to revert back to 6.0.41. How do I do that?

    Many thanks!


  12. I hadn’t logged in for a while to the controller. I can get to the sign in page, but it won’t accept my user name and password. Any way to reset the password or do I need to do a fresh install?

    • You will need to do a fresh install. Tip for the next time, enable remote access on your controller. This way you can use your cloud credentials to login (and reset your password in the cloud)

      • Sometimes if you are out of space the controller freaks out and freezes you out of logging in.
        If you reboot the controller log in immediately and do a back up.
        Make your drive larger and then restore your back up.
        Lower the number of days you retain data and keep an eye on used space. Occasionally the Mongo Database fills up with outdated material.
        That should solve the issue if it’s related to running out of space.

  13. I changed the host name on the unifi admin config page, and now when i restart the container I can’t access the UI. nothing will come up.

    How can i restore my settings from a backup from the synology file station? i can see all the files un the unifi volume. i just don’t what to replace

      • Ok. I was able to solve the immediate problem of accessing the unifi page. I deleted the keystore file from the unifi volume. the restarted. the setup page came up and i loaded a backup config file, and all is well.

        So the question now is, how to install the certificates i use on the synology into the unifi controller app? so i get a trusted certificate.

  14. Hi Ruud,
    ik probeer een update te installeren voor de Unifi.
    In de software krijg ik de melding dat 6.0.45 beschikbaar is en bij de ‘register’ zie ik die ook als ik naar beneden scroll.
    Maar de container die ik heb heeft de tag ‘latest’. Als ik deze registreer en download en volgens jouw aanwijzingen eerst de container wis en daarna weer opstart krijg ik echter volgens het inlogscherm versie 5.12.66 te zien.
    Gaat er iets fout? Want ik kom van 5.12.66 af

  15. Good Day Ruud,

    I’ve been following your information for some time now and find it very informative. I’m sure that over the last week or so you noticed a major update to the ßeta Unifi Controller 6.1.51. What I was wondering is if you have any InSite into just how one would manually pull a copy of the Jacob Alberty docker files for this version?

    I’ve read his information outline, and see that he has indicated a number of command switches to facilitate the download of the various ßeta installs, however, I’m unable to get it to work for me…

    Do you have any thoughts on just how one would go about completing this task?
    My Regards

  16. Not seeing my APs.. It would pop up during setup and when I finalize it, I get an error.

    reinstalled a few times. i’ve reset my ap a few times as well.

  17. Hoi Ruud,
    Dit is echt super man, subliem!

    Bedankt voor de info. Draait als een zonnetje met de info die je me leverde.
    Na de aanschaf van de 220+ heb ik je sources gedownload en je manual gevolgd.
    Werkte in 1x. Thanks!


  18. Worked like a charm.
    I used the option to restore from a backup file (from Windows10) which I uploaded from within the browser.
    (It did not work to just copy the backup file to the NAS, it was not recognized)
    It took some time for the new controller to adopt the devices.
    Thanks so much for making life easy today.

  19. At the sign in page it has the option to restore from backup which I used. Neither the ubnt/ubnt nor my normal login work. Should I sign in first and then restore my backup?


    • Yes, you should first sign-in (walkthrough the basic setup) and then restore the backup. It’s a common issue that you can’t sign-in after you did a restore during the initial setup.

  20. Hi again Rudd.

    Loaded it into my Docker container on Synology and it does not accept my login credentials. Running the same version on both controllers (5.14.22)

    Any suggestions how to log into the new controller?


  21. Very nice manual, thanks!
    I followed it step by step, but ran into a problem. After I’m finished configuring (including firewall rules), rebooted the NAS and started the container, I go to https://:8843. This error message follows:

    HTTP Status 400 – Bad Request

    No login screen, just this message.

    I think the problem is related to ports, because when I manually change the ports, it works. But I prefer using the standard ports.

    Does anyone have a solution for this?

  22. Installing Unifi controller on Synology or Raspberry Pi?

    Thank you so much for all your different tutorials! They’re really helpful.
    I got quite a luxury problem having both at home. A Synology NAS and a Raspberry Pi 4. Right now the Unifi controller is running on the Synology.
    Which is the better place to run it on? Is there an answer to that question?
    Would be nice if you could leave a comment about this.

    • That is a good question. I prefer the Pi, because that makes the network configuration part a bit easier. With docker, you need to map ports etc to install an SSL cert for example. This makes it a bit harder to configure it. A PI is a bit easier.

      But I would make sure you have a model 3 or 4 Pi at least. Otherwise, the Unifi Controller can be really slow to work with.

      • Thanks for your quick reply!
        Your answe matches with my gut feeling.
        So, will install the Unifi controller on the Pi. Another new project.

  23. Trying to update to the new 6.0 docker image, but not sure how to do this as the default image on ‘latest’ is still the 5.14 version. Any tips would be very welcome! Thanks.

  24. I have just installed Docker in order to create this written setup.

    Everything is setup, but I cannot reach the controller. My webbrowser cannot open the URL. I am using DSM 6.2.3-25426 Update 2.

  25. Well – I gave it another shot after adding ram to my nas – hence a reboot – and it now magically works. I don’t ask questions, just enjoying the results. Thanks for the guide!

  26. Had followed the instruction to the letter to deploy on a DS920+. Setting up go nice. As soon i can access settings interface and try to modify settings, i get a ton of errors saying that some settings could not be updated. Also clicking on left side button often
    head me to 400: Bad Request Please to get back to the homepage.

    here is the chain of errors i get as soon i want to change site name:
    There was an error saving the settings_site_key_lcm changes.
    There was an error saving the settings_site_key_network_optimization changes.
    There was an error saving the provider capabilities changes.
    There was an error saving the speed test changes.
    There was an error saving the rsyslogd changes.
    There was an error saving the settings_site_key_element_adopt changes.

    Then looking at the server log on Syno (/docker/unifi/log/server.log) i see that error :

    [2020-09-02T22:42:06,588] ERROR api – Failed to update permissions: I/O error on POST request for “http://localhost:11081/api/permissions/network”: Connect to localhost:11081 [localhost/, localhost/0:0:0:0:0:0:0:1] failed: Connection refused (Connection refused); nested exception is org.apache.http.conn.HttpHostConnectException: Connect to localhost:11081 [localhost/, localhost/0:0:0:0:0:0:0:1] failed: Connection refused (Connection refused)

      • Thank you Ruud.
        Nevermind, the issue lies with me using my domain (same as external) for which i may have an issue. Browsing that container with ip on Syno brings no errors anymore.

  27. Hi!

    Thanks! My issue is that I can’t access the Unifi controller once I’ve done all the steps and I can’t figure out why. Any suggestions of where to look? Error message:
    This site can’t be reached refused to connect.

    Checking the connection
    Checking the proxy and the firewall

    Please do note that my DS216+II is not my firewall on the network hence the .77 address. Would there be another setting I should look for in the NAS?


  28. Good Day Rudd,

    I’ve been looking all over for information on installing a Letsencrypt SSL Certificate for Unifi Controller on a Synology Docker Install.

    Would you have any pointers to such information? Or, if capable would you perhaps work on a tutorial that would outline such… Thank you so very much

    • – Install letsencrypt certificate on the Synology in Control Panel > Security > Certificate.
      – Right click on the certificate and export it.
      – Extract the zip file (contains cert.pem, privkey.pem, chain.pem) to a folder on the Synology.
      – Stop the container.
      – Edit the settings. Under volume, mount the folder containing cert.pem, privkey.pem, chain.pem to /unifi/cert. I made the mount read-only but it isn’t necessary.
      – Start the container.


  29. Hallo Rudy thx for the guide. Everything goes well however i don’t see any environment variables under the environment tab when I try to launch the image. When I launch it nevertheless I can’t access the page on port 8443 even without the firewall enabled. Any clue?

  30. So while things were working just fine, I couldn’t get the original container to turn on… and got this error message:
    Start container Unifi_Controller failed: {“message”:”Bind mount failed

    So I decided to download the latest image again, and go thru the motions of doing an update. When I was done, I ended up with 2 containers (unifi and unifi1). Without knowing what was happening, I ran thru the settings, which needed to be altered, and used the same path as the original container, which I’m assuming has basically deleted all the original files for the 1st Unifi Controller.

    1st, what might be causing the error message, and how might I fix it.
    2. Assuming the original data has been overwritten, and without a backup, I’m guessing Ill have to do a hard reset on the devices to regain control, right ?
    3. I also can’t access the *new* container by the usual method, so assuming I do have to hard reset the devices, how do I log into the new container?

    • so the good news is that I got it to work again. Turns out I didn’t overwrite the original settings, etc, so was able to salvage them. I copied the data and logs folder to a different location on the NAS, uninstalled Docker and all of the containers, files, etc, and started over, making sure to uncheck “Run after setup”, which is when I coped the data and log folders back to the right location for use in Docker. Bottom line is finally got it to work. Still not sure what caused the original issue with not being able to launch the controller… but for the moment, it’s fixed. And more importantly, I have a backup of what appears to be the most important “stuff”, so I can go thru these motions again if necessary….

      Honestly, this is a huge blessing to have this working. This is the 2nd install of this configuration, and can’t thank you enough for taking the time to work thru this, making a super tutorial, and help out along the way.


  31. Greetings,

    Following the upgrade instructions has become a disaster. My Unifi controller had been running correctly, now, it cannot be accessed from https://[synology IP]:8443 (can’t connect to server error). Accessing it from a “desktop shortcut” on the DSM interface brings up a controller at [DDNS], but it cannot access the internet.

    Have you upgraded recently? s this just me or did synology/unifi break something?

  32. Hi, Great tutorial and works a treat.

    Have a problem – I am running some older APs which are no longer supported by the newer versions of the controller.

    I need to use a controller that is ideally version 5.6.42.

    Is there anyway I could adjust or you could provide a way to downgrade your great install on the Synology Docker to this version?

  33. Great tutorial, very detailed. Which makes me look bad because I was not able to get it to work on my Synology.Lol

    When I start the UniFi container it will crash and restart endlessly. I was able to get a pi-hole and UNMS container up and running with no problems. So I think my instance of Docker is working correctly. Have you ever heard of this? Can you suggest any troubleshooting techniques I should try? Any advice would be greatly appreciated.

  34. I did my first update to the container image today and your instructions worked flawlessly. Any idea what the “clear’ command equates to in the docker command line? The reason being there is so little documentation on image updates outside downloading most current image, remove the old container and creating a new version with the tagged version of the new image. If clear maintains the docker settings for the original container I would love to script around it.

  35. Hey rudi,

    thanks a lot for the great cook-book 😉

    I just have two question, it’s already mentioned here in a different way:

    Where do I have to put the config.gateway.json file when I use the docker container?
    How can I test whether the new config was loaded (in my example no double-NAT)?

    I would appreciate any hints 😉

    Best wishes!

    • The config.gateway.json should be placed in /unifi volume under /unifi/data/sites/[site name]/.
      I have no idea how to show the running-config for the controller. For the access points and switches etc you can log in to SSH and use the CLI for this. For the controller, as far as I know, you can only check the settings in the GUI.

  36. Great hoot, thanks! However I try to access the Unifi controller thru IOS app, but get error “json could not be serialized because of error”. Any ideas how to solve this?

  37. Hello, Rudy;

    I wanted to thank you profusely for this post and the work you did putting this container together. My Diskstation is the only device running in my house 24/7, and I really had no other system on which to maintain one. This solved that problem.

    My FlexHD AP is the only Unifi device on my network at the moment (I have a Ubiquiti EdgeRouter X, but it’s internally manageable, can’t manage it on the controller). My plan is to replace two cheap switches with Unifi 8-port devices, so now I can add and manage them from this controller.

    I wanted to provide a couple of tips to others so they don’t do what I did.

    I created the original controller on a Linux laptop, not realizing that it would have to be running with the controller loaded to access it from anywhere. If you do this, back up the controller configuration before deleting it to install it on a Diskstation. This makes your setup a lot easier.

    Also, one nervous moment I had: I had to hard reset the AP to start your process fresh, and when I did, the FlexHD went into a non-stop blue and white blinking phase. I waited some time for it to go into configuration mode (steady white), but it didn’t stop blinking. The Unifi user guide for this device was crystal clear about not “touching or powering down” the unit while it did this.

    I found a post on the company’s community forum that stated this was probably the result of the unit being in TFTP mode, and powering the unit down would be OK. I did that and after a moment, it restarted and went solid white. I connected to a laptop plugged into the LAN, pointed the browser to your Docker container on the Diskstation and everything worked perfectly configuring the new controller. I can now access the controller from my Pixelbook and remotely with the Android app. (The latter isn’t so important right now, since we haven’t really been outside much for about a month

    Everyone read this again: Do. A. Controller. Backup.

    Again, thanks so much for your great work and in making this available to everyone.

    Joe in Florida.

  38. Good Day Ruud

    As a follow-up note to my comments of January 2019, I wanted to express my gratitude to you again for the incredible efforts you have put into this method of facilitating the Unifi Controller in Docker with a Synology NAS.

    Indeed, I installed in un under 5 minutes and have been able to update to current versions of the controller without problems of errors ever since.

    I remember discussing facilitating the Beta line of controllers back then with you. Would you consider facilitating that channel now to users that want to go down that path?

    This could be a total separate channel from your mainstream update? And, in fact could be limited to only those that would support themselves. Given the long-time delays between the release versions, and the number of test/beta versions of the controller, the improvements/updates in the Beta stream correct a number of problems that some of have with the older controller versions.

    Again, thank you so very much for all your efforts…. Cheers…

  39. Good stuff
    I would like to know if this would allow me to add additional sites to my Unifi Cloud Controller? or this set up is for one location on the Synology system.

    • You can add multiple sites to the controller. If those sites are remote (and they probably are), then make sure your forward the correct ports to the Synology and use secure passwords.

  40. I signed up for your email newsletter but I’ve never received one. Can you help?

    Just followed the instructions to update the controller — perfect!!! Thank you!!!

    Do you run a pi-hole on synology DS as well? I bet that would be another much loved how-to.

  41. Hi and thanks for your excellent guide. I struggle getting the unifi-controller finally up and running. The container is deployed, but when I access the URL I only get some set of icons:

    On the same DSS only Plex is running – but on a different port. Any ideas what I missed?


  42. Hi, fantastic guide – helped me a lot to get started. But I still struggle to get the Unifi.Controller working. When I access the site (https://IP:8443), I only see these icons: �. Besides Docker I only have Plex running… do you have an idea how this can be fixed?


  43. Thank you very much! It was very easy to install with these instructions.
    I just had one problem on the install and that was the Docker container kept crashing and restarting. In the log I found that port 8080 was already in use. I have a lot of packages running on my Synology and I found out that SABnzbd was already using port 8080. After changing the port in SABnzbd to port 8888 and restarting and reinstalling the Docker container everything worked like a charm.

  44. THANK YOU!

    Your instructions were very clear and super easy to understand. I was able to get this done with little effort.

    Past that, I was able to use my old URL and change localhost to the IP address of my Synology server and was able to log into the controller, and got everything up and running. I’m actually doing the same install on 2nd Synology… but… is there a URL that is easier to use to access the controller? I know I need to be on the same LAN, but…. any info on this will help.

  45. Hi Rudy,

    I have installed the controller and it works like a charm! 🙂

    The only thing is dat i can’t see the json files within the controller.. all the other files i can see.

    Do you have an idea why this is?

      • Hi Rudy,

        I can’t find any of the site related jason files.

        They are nog on the unifi folder on the nas..but are on the controller..

        Kind regards

  46. Hi,
    following this great tutorial (already installed successfully on one DS1511+) on a DS1819+ in stuck with this error at last step :
    “Create container Unify-Controller failed :{“message”:”error creating overlay mount to /volume1/@docker/overlay2/…alphanumerical…-init/merged: invalid arguments”

    I’ve tried to change the path of the shared folder to /volume1/docker/Unifi, /docker/Unifi… Same error.

    I’ve been struggling and searching for ours… unsuccessfully.

    Can you help me find a way to the solution ?

    • Hi,

      I think may point you in the right direction:

      As per docker documentation: “To set the storage driver, you can use the –storage-driver flag when starting the Docker daemon manually, or (recommended) set the option in the daemon.json file, which is located in /etc/docker/”

      daemon.json content:

      { “storage-driver”: “devicemapper” }

  47. Hello, thanks for this tutorial. I almost have it up and running, except for 1 thing.
    I have exported my old controller site and imported it to the one on the Synology, but now my old login details are not working anymore. So I cannot login anymore. I expected with export/import of backup the accounts would also migrate?

    • Did you try the default username and password ubnt/ubnt? With login credentials are not exported with the site export. You could also try to restore a backup file from your old controller.

      • Hi Rudy, unfortunately the default login did not work. I did a clean install and started from scratch. Now it is working. Thanks for your help!

  48. Thanks for the guide.

    All works, except for one thing, Unifi cannot find my AP-AC-LR.

    The AP is already configured and I wanted the Unifi controller to adopt the AP, but as I said, it cannot see it at all.


  49. HI Rudy – thanks a million for this great tutorial. I don;t think I would have ever got it running without the clear step-by-step instructions. It is working great – but will need to go through one update cycle to see how that goes …
    Please also subscribe me to the updates as it is running now and intend to update when you refresh the latest install.
    Great work!

  50. Hi Ruud,

    Great Tutorial. Many thanks!

    initially, I had an issue: Docker version 18-09-0-05-0506 did not run after install. However, via a pre-install of Docker version 17.05 (and then upgrade) , docker appears to work.


  51. Hello,

    Thanks for the tutorial. I followed it step by step on my DS412 NAS server and everything is setup.

    Just one problem. Clicked into the Controller and on Step 2 of 6 (Sign in with your Ubiquiti Account). Where do I get that username and password from?

    FYI: I’ve not bought any Unifi products yet, but is it possible to go forth with the set up without hardware, or is this where it ends for me until my AP arrives.

  52. This is a great article, thank you!

    I’m try to add a custom config.gateway.json file, but I can’t find where to put it. Everywhere says to add it to the “sites/default” folder (if you only have one site), but I don’t see that in the Docker/Unifi folder we created.

    Any help you can provide, would be greatly appreciated!

    • Just to update. This was usable for a few days but ever since I get constant “Docker container stopped unexpectedly” message, high cpu used by docker, and no access to the web interface.

      I really hope a cloudkey comes on sale one day, all these workarounds are so too unreliable.

      • Re-installing ocker fixed it for now. I uninstalled docker, but kept container and settings, then installed again. The errors in the docker log at the time were:
        “docker failed to initialize logging driver: database is locked”
        “docker api has failed”

  53. Thanks to your article about installing the Unifi controller on a Synology NAS using Docker.
    I am currently having a problem getting to view the system logs.

    I have tried asking Ubiquity but they do not seen very helpful.

    How do I add graphics to the comments?

  54. Hi,
    After installing the version for and try to create a manual backup I get an error “There was an error creating backup file”
    What have I got wrong/missed?
    Looks like autobackup may be working but too early to be sure.

  55. Hi,

    Container works great, but the backup function isn’t writing to /docker/unifi, it dumps to my windows Download folder instead (when accessing web interface through Chrome).

    Any ideas?



  56. Hello. Thank you for the install guide. Brilliant and it worked 1st time! Maybe I’m being a bit thick… but I can’t find the subscribe button for controller updates? Thanks again.

  57. Hi Ruud,

    thanks for this easy to follow explanation. Worked like a charm.

    Could you please add me to your mailinglist? That would be great!

    Thanks and kind regards,

  58. Hi Ruud,

    Great Tutorial!!
    I also would like to be subscribed for the Unify Controller updates on the synology NAS, can you add me to the list as well?

    I didn’t change the two settings to “false” but left them on true. I guess that isn’t a problem. First I had some issues with the container restarting every minute due to ports conflict. Then I left the statements to false and it resolved. But probably it was another issue that made it work again I guess.
    Also I followed this video of your container. I changed however the path tot /Docker/Unifi as you described.

    I’m new to unifi and ubiquity stuff so I’m learning a lot.

  59. So for everybody who has problems with a regular error entry regarding the ports (like 8080) after first startup.

    Some other docker app or other application running on your diskstation is listing on the needed ports, so we need to tell the unifi to use other port numbers.

    There are at least two solutions:
    – Don’t use the same network as in the instructions above mentioned
    – you can now use the portmapping inside of docker like mapping 8448 of unifi to 18448 of your diskstation, remember that you give a dedicated port and don’t let docker decide on “auto” what the best ports could be, this will let in worst case to changing ports after each reboot.
    – or after a first succesfull boot of the unifi you can edit the file which should be in the following location, if you followed the instructions above: docker\Unifi\data

  60. Hi,

    Great guide. Question, do you know hwo to change the ports? I already have sites running on 8080 and 8443.

    Thank you!

  61. Hey Ruud,

    thanks for your great tutorial first – even for a noob like me its been pretty easy to install the Docker version of the Unifi Controller.
    Now I am up to the next task: my first update. After downloading a new image I find two options under Action/Clear, one simply called “Clear” (or “Löschen” in german) and another one “Inhalte löschen” – dont know the exact englisch translation for this button in the Synology DSM. Which one should I chose? 🙂

    Thanks for helping!

      • I think it’s the other way around: “Inhalte löschen” leaves the container in place and allows for the new image to be loaded. “Löschen” deletes the container and you have to reinstall the whole thing in docker.

  62. Thanks for the guide. Works great on DS916+.

    Any idea if the MongoDB installed is 64 or 32 bits? How to check?

    Does this Docker installation shutdown the Unifi Controller prior to NAS reboot or shutdown?

  63. Hi Ruud,

    Thanks voor your manual.
    Everything up and running on a DS1513+
    Is there somewhere a manual which describes all the Unify options and settings
    I’d like to be subscribed for Unify Controller updates

  64. Hi Ruud – Your guide is the best thank you!

    After great success installing both the initial controller and the recently updated image, when I follow your steps, the controller updates to the new version but it appears this leaves dependencies on both the old and new image. Is this normal? I was hoping I can delete the older image version to save disk space. Thank you.

  65. Great tutorial! Especially the Update part was very helpful.

    Do you know how to automatize the update or doing it via shell? So that a cronjob script could check weekly for updates and perform them.

  66. Hi I am novice at using docker ….. I followed your tutorail and installed the Unifi Video sorfware. I also installed the latest Java. The Unifi Software seems to be running stably – although the CPU usage fluctuates a bit. (when I first installed without Java it crashed every minute).

    How do I access the NV software do I use the Unifi discovery tool from my main pc ………. ??? Also do I need to install some form of cloud key in another docker container??? I am a little confused can you help.

  67. I found a workaround to install the Unifi docker with the original ports.

    I had the feeling the DDSM (Docker DSM) was blocking/using all ports. So 1st I tried install Docker in DDSM. This is not possible. Synology does not accept a Docker inside a Docker.

    Then I went to VMM (Virtual Machine Manager) where I installed a Virtual DSM. Inside the New Virtual DSM I installed a clean Docker, in which I installed the Unifi Controller without any issues as described in this manual, and I can access it over https://IP_of_VDSM:8443

    I hope this workaround is useful for other users.

    So far, thanks!

  68. Hello,

    I think my issues are more or less the same as the issues of Frank Mauritz, David and Giuseppe A. Continisio.

    1st I installed according to your manual, using the “Use the same network as Docker Host” option. Doing this, the Docker crashes within 1 minute, with the error port 8443 is not reachable.

    2nd I installed using not tagging the “Use the same network as Docker Host”. When I go to the tab with the port settings, I change all ports to the standard ports. Docker reports all 6 ports “value already existing”. The docker is not starting.

    3rd I installed like the 2nd time, except assigning other ports (f.i. 18443 to 8443). Doing this, I was able to start the package, and to run run it over //ip_of_nas:18443/

  69. The Error message in the Log file is:
    [2019-03-25T23:48:49,287] WARN system – reload failed: file not found
    [2019-03-25T23:49:01,800] WARN system – reload failed: file not found
    [2019-03-25T23:49:14,132] WARN system – reload failed: file not found
    [2019-03-25T23:49:26,241] WARN system – reload failed: file not found
    [2019-03-25T23:49:38,456] WARN system – reload failed: file not found
    [2019-03-25T23:49:50,622] WARN system – reload failed: file not found
    [2019-03-25T23:50:02,716] WARN system – reload failed: file not found
    [2019-03-25T23:50:14,839] WARN system – reload failed: file not found
    [2019-03-25T23:50:29,753] WARN system – reload failed: file not found
    [2019-03-25T23:51:05,342] WARN system – reload failed: file not found
    [2019-03-25T23:52:13,475] WARN system – reload failed: file not found
    [2019-03-25T23:55:29,928] WARN system – reload failed: file not found
    [2019-03-25T23:59:17,251] WARN system – reload failed: file not found

  70. Hello,

    I tried to install the docker according to your manual on my DS1515+ / DS6.2.1 / 16GB, but the docker crashes within 1 minute every time I try to start it. Do you have any clue where I could search to solve this?

    Thanks in advance!

    Kind regards

    • I think re-installing docker should fix this. If you search on the error you will notice a few others that have the same problem. A few of them solved it with re-installing Docker. Make sure everything is up-to-date.

  71. Hi, I’ve been running UniFi in Docker on my Synology for a few months now and have already been through a few upgrade cycles. Currently running 5.10.19. Tried upgrading to 5.10.20 tonight using “latest”. Everything appears to go ok however UniFi loads as the old version. Any ideas?

    One other thing, when I stop the container and select Action > Clear, the container disappears. I need to close the Docker window and open it again for the container to be visable again.

  72. Hello Rudy
    fantastic information.
    Everything works OK but I run into a problem, I can not adopt any device in any SITE created in my controler.

    I use Unifi Discover and I pass the address of my controller on the NAS,

    but the device never seems to be in the controller for adoption.

    What URL should I use in a Controller of this type?

    Thanks in advance.

    Jaume Duch

    • The address you are using won’t work. address is a online address, the Unifi needs a local address. Try to use the ip address of the Synology instead.

  73. Hi!
    The installation was done without any trouble. I downloaded a site saved on another controller. I can import it to the nas. When I reached the webpage of the controller, I got to enter a login and a password : it entered the one I use on my “old” controller, but it doesn’t work. I click to rest the password : impossible to do it.
    How to solve this?
    Thanks in advance!

  74. Hello Ruud

    thank you so much for sharing your know-how.
    I followed step-by-step your guide, and I was sure, everything was ok.
    Unfortunately after starting the process I was not able to reach the site on https://syno_ip:8443.
    If I have a look at the server.log file the only thing I find is the following sequence
    “[21:27:04,772] WARN system – reload failed: file not found”
    and this after every 14 seconds.
    The Synology notification says
    “Docker-Container: unifi-Controller wurde unerwartet gestoppt.”
    In the Docker Container I can observe how the cpu and ram jumps up and down.
    The protocol has for all 12 seconds the following entry
    “Port 8080 not available”
    “[2019-02-16 21:51:38,755] WARN: unifi service process ended without being singaled? Check for errors in /unifi/log.”
    “[2019-02-16 21:51:40,225] Starting unifi controller service.”

    I don’t know how to treat the port error.
    My Docker runs only this container.
    What could it be?

    I hope you have an idea.
    It would be glad.

    Best regards.

  75. Hi,

    thank you for the excellent tutorial. Could you help me with 2 questions please:
    1. why should be those 2 parameters set to false?
    2. I need to chage the communication ports, as the 8443 port is already used by different application, is it possible to change it somehow within the docker?

    Thank you


    • Hi David,

      RUNAS_UID0 is set to false so the image will run as a special unifi user. Otherwise, it will run as root. The BIND_PRIV variable can be used to bind port below the 1024. But on some docker filesystems, this may not work.

      To change the ports, you should be able to change this in the file. You will find it in the File Station/docker/Unifi/data. More info about changing ports here.

      • Thank you for the reply.
        I wrote the path /Unifi and it did not save any files to the folder, when I changed it to /unifi files and folders showed up in the docekr/Unifi.

        However I have one more problem. When I start the container and restore the settings from backup everything works fine for a while. I can connect to the controller from the phone and everything works. When I quit the app on phone and reopen the controller on iMac it shows no devices and no clients. It looks like it does not remember the settings.

        Could you help me please? Homebridge container is running in the docker as well.

        In the terminal of the container I found following errors:
        Feb 12, 2019 7:31:26 PM org.apache.commons.httpclient.HttpMethodDirector executeWithRetry
        INFO: I/O exception ( caught when processing request: Connection refused (Connection refused)
        Feb 12, 2019 7:31:26 PM org.apache.commons.httpclient.HttpMethodDirector executeWithRetry
        INFO: Retrying request

        • Hi David,

          I looks like you need to update Java or change the path to your Java installation. You can try using this guide to update Java in your Docker, or try to update the path:

          Please edit the file "unifi" in /etc/default/

          For example:
          #JAVA_HOME=/usr/lib/jvm/jdk-8-oracle-arm32-vfp-hflt => old
          JAVA_HOME=/usr/lib/jvm/java-8-oracle => new

  76. Great information… Worked for me the very first time… I would however like a little more info on doing upgrades to my controller.

    How often do you update the links? And does the beta download correspond with Ubiquiti’s beta cycle?

    The reason I ask is I wanted to try the Beta controller to see what improvements it may contain and was not sure if your download link contained the latest beta code.

    Thanks in advance

    • Hi David,

      I don’t link to the beta downloads. I check the versions one in the month and update them if necessary. You can subscribe to the email list, then you will receive a notification when a new version is available.

    • Hi! Thank you for this! I have some problem with your instructions.
      I dont have button “advanced options” in general settings.
      How i can activate it?
      Nas 710+
      OS 5.2 this is the last for me.

  77. Hallo Ruud,

    danke für die gute Anleitung (Unifi Controllers/ Synology Nas). Nichtsdestotrotz habe ich ein entscheidendes Problem!
    Im Docker Container kann man sehen das der Controller funktioniert, aber ein Zugriff auf die Benutzeroberfläche ist nicht möglich.
    Die Controller Oberfläche öffnet sich nicht, sondern eine Collection Listing die einen Strukturbaum ähnelt. In der „Collection Listing“ befindet sich kein Eintrag hinsichtlich Unifi Controller.
    Gerne kann ich Ihnen hierzu auch Screenshots zusenden.

    Vielleicht können sie mir helfen, ich wäre Ihnen dankbar.

    Mit freundlichen Grüßen

    Frank Mauritz

    Hello Ruud,

    thanks for the good instructions (Unifi Controllers / Synology Nas). Nevertheless, I have a crucial problem!
    In the Docker container you can see that the controller is working, but access to the Unifi Controller is not possible.
    The Unifi Controller does not open, but a collection listing similar to a tree structure. In the “Collection Listing” there is no entry regarding Unifi Controller.
    I am happy to send you screenshots as well.

    Maybe you can help me, I would be grateful.

    Yours sincerely

    Frank Mauritz

    • Hi Frank,

      Do you have anything else running on your Synology that might be using the same port? You can find my contact details on the about page to send me a screenshot.

    • Hatte das gleiche. Bei dir ist der CARDDAV Server aktiv. Einmal Ausschalten!

      (translated: Had the same. With you the CARDDAV server is active. Turn off once!)

      • Had also the same. Deleted CARDDAV. Problem persists. Must be something else. Not quitting 🙂 Running it in a VM also, where it works. In a container would be less demanding though, in terms of hardware ressources, so am I am still intrigued to get it to work. Any help is appreciated of course. THX

Leave a Comment