Unifi Network Application / Docker Help

ScottulusMaximus

Honorary Master
Joined
May 9, 2012
Messages
10,665
Reaction score
3,855
Location
Snor City
Hi all! Firstly in this I am clueless, pretend you're speaking to a 2 year old.

Trying to get the new Unifi Network Application set up on my Asustor NAS with docker. It requires dependencies and what what and I'm clueless.

I've tried the below all in one solution:


But getting the below error:

./install.sh: line 23: syntax error: unexpected "("

I'm clueless.... Took me 3 hours to get this far.

It can be done manually and I have the following installed, looks like it definitely can be made to work:

https://www.asustor.com/en/app_central/app_detail?id=1603&type=
https://hub.docker.com/_/mongo
https://hub.docker.com/_/mongo-express

I just have absolutely no idea how to add the scripts(?) required. I've copy/pasted the .yml files from the github into the MongoExpress document makes but says invalid JSON file, !@#$ knows what that means.

Any help would be appreciated!
 
Send me your WhatsApp number and I'll assist if possible.
The below worked on my Synology NAS 218J

Prerequisites



  • Make sure you log in to DSM on your NAS as an admin user
  • Docker must be installed on your NAS. If It isn’t, go to "Package Center", select "Utilities" and look for "Docker" under the "Third-party" heading and add the package to your NAS (if Docker is not available for your NAS, this HOWTO is not for you).


Installation



  • In the (DSM) Main menu, choose "Docker"
  • Click on "Registry" and search for "unifi". Select the "jacobalberty/unifi" entry and click "Download". Select the "stable" branch.
  • When the image is downloaded, it’ll show up under "Image", on this page select it and click "Launch". Note that it can take a while to finish the download, DSM will show a "system event" notification when the download is completed.
  • Give the controller a container name you like (or accept the default) and click on "Advanced Settings". Here:
    • In the first tab "Advanced settings", check "Enable auto-restart"
    • In the tab "Volume", click "Add Folder"
      • Select "docker", click on "Create folder", name it "unifi" and click OK. Select it and click "Select"
      • Under "mount path", enter "/unifi"
    • In the tab "Network", check "Use the same network as Docker Host"
    • In the tab "Environment", scroll down to the bottom of the environment variables list:
      • Look for "BIND_PRIV" and set its value to "false"
      • Look for "RUNAS_UID0" and set its value to "false"
    • Click "Apply"
  • Click on "Next" and after that on "Apply"


That’s it! Unifi Controller should be running now, it’s accessible on your Diskstation on port 8443, use https to connect to it (or use the app on your mobile device).



Please note that if your firewall is enabled on your NAS, you need to allow access to TCP ports 8080, 8443, 8843, 8880, and 6789, and UDP ports 3478, and 10001 (Control Panel -> Security -> Firewall).



If the controller is not reachable at this point, it might be necessary to reboot your NAS. Both Docker and UniFi Controller should start up automatically.
 
I just have absolutely no idea how to add the scripts(?) required. I've copy/pasted the .yml files from the github into the MongoExpress document makes but says invalid JSON file, !@#$ knows what that means.

Any help would be appreciated!
As XL posted,rather go for an All-in-one image if you aren't too familiar with docker,and rather use a docker run rather than compose to bring up containers
If you use something like portainer you can then use the web GUI to easily change the container to run permanently rather than once
Jacoalberty or Linuxserver's Images have worked for me on the Unifi Side
 
Plox halp!

I've got nowhere on the main menu to click on "Docker" to do anything with it, just runs in the background as the engine.

Portainer shows me the HomeAssistant container running and makes sense to me. How do I get the Unifi running in portainer?
 
Is Unify even running? Do you have a command line to access? Not making sense

Did you do the setup steps and do an initial run?

mkdir -p unifi/data
mkdir -p unifi/log

docker run -d --init --restart=unless-stopped -p 8080:8080 -p 8443:8443 -p 3478:3478/udp -e TZ='Africa/Johannesburg' -v ~/unifi:/unifi --user unifi --name unifi jacobalberty/unifi
 
I'm sure I'm talking gibberish, don't know what to ask, I have this in Portainer pulled from docker hub:

1715790367822.png

And absolutely 0 clue how to get the network application to "talk" to mongo.


Has to be mongo 4.4 due to limitations on my NAS' CPU. I'm sure somewhere in those links there's instructions someone with half a brain will uderstand but I don't.
 
Oh I see,nuke the mongo and the unifi you pulled. There's a mongoless Linuxserver image you didn't use,or just use Jacoalberty as stated earlier, it's mongo is built-in which is a simpler "all in one" for you
 
Oh I see,nuke the mongo and the unifi you pulled. There's a mongoless Linuxserver image you didn't use,or just use Jacoalberty as stated earlier, it's mongo is built-in which is a simpler "all in one" for you

Ok, but how?

And is it the new unifi network application or the old network controller?
 
Are you dead set on the new Application (I assume this is the one that combines UNMS and Controller)?
Most of us run the Classic Controller from Jacoalberty or Linuxserver
 
Ah right,eh i'll have to check the docs for connecting to Mongo on the App docker. Most people won't upgrade to Bleeding Edge unless the old ones stop working :ROFL:
 
I ****ing give up, can't even get controller working now, won't connect. Presume it's port forwarding as that's what the error the container is giving:

Error 500 starting userland proxy: listen tcp4 0.0.0.0:8080: bind: address already in use

But Home Assistant and Portainer connect fine.

Or I borked something that's locking the port on boot with all my fiddling. Can't get into root to clear out all the folders and crap I've put in there.
 
Last edited:
Create a new stack in Portainer, copy and paste everything in this yaml file:


And just edit the volumes to be actual paths.

Done.

Just remove the other one and the db you already made.
That is the yaml file I ended up using after struggling for hours to get the Unifi container to talk to the MongoDB container on my Raspberry Pi 4.
 
Error 500 starting userland proxy: listen tcp4 0.0.0.0:8080: bind: address already in use
Whenever you see this: Another docker is using the same listening port - 8080 in this instance
Usually as simple then as just changing either the new one or the existing one's ports
 
Create a new stack in Portainer, copy and paste everything in this yaml file:


And just edit the volumes to be actual paths.

Done.

Just remove the other one and the db you already made.

Woot! Finally seems to be running and using CPU and memory, had to use the old compiler and change the ports because my NAS uses the same ones :

1715849023603.png

Still can't access the web UI though, connection refused? How do I actually get "access" to the service now?
 
Woot! Finally seems to be running and using CPU and memory, had to use the old compiler and change the ports because my NAS uses the same ones :

View attachment 1710015

Still can't access the web UI though, connection refused? How do I actually get "access" to the service now?
You sure the destination ports in the container is correct?

The port to the left in Published is the "external" port,the port to the right is the "internal port" in the container

Like I can tell docker to accept a connection on port 10000 and send it to port 443 in the container,but port 443 must be listening in the container
 
You sure the destination ports in the container is correct?

The port to the left in Published is the "external" port,the port to the right is the "internal port" in the container

Like I can tell docker to accept a connection on port 10000 and send it to port 443 in the container,but port 443 must be listening in the container

That was it, I just brute forced and ignoranced and changed all the port numbers that matched
 
I think the controller wants to use 8080 by default, you might have to browse to the path you set in the file and edit the system.properties file and change the port and also in the web UI you will have to change the inform host IP and port to your NAS IP and the port you're using now, it will probably be set to your Docket network IP which won't be accessible to other devices.
 
I think the controller wants to use 8080 by default, you might have to browse to the path you set in the file and edit the system.properties file and change the port and also in the web UI you will have to change the inform host IP and port to your NAS IP and the port you're using now, it will probably be set to your Docket network IP which won't be accessible to other devices.

My NAS Web GUI log in was on 8080 and 8443, I've changed those now so Unifi is using the defaults.

Do I still need to do the above to adopt or can I just reset the devices?
 
Top
Sign up to the MyBroadband newsletter