Re: 404 error. @Archonite @TekDRu
your mileage may vary but...I ran into this (a lot) and after some google-fu, found it to be an '@' symbol in my password, and some 'legacy' config from adjusting and moving things around.
Connection to the DB must be successful (beyond the unifi-network-application 'logs' no longer showing connection errors to the DB' ; that appears to just be network connection test versus authentication test
1) the image will 'stick' the database/username/password' in the config as a one time go/only evaluated on first run. You have one shot to input it correctly. if you change the username/pass, you *may* need to recreate the docker container.
1a) I was able to validate this by going to unifi-network-application console, and viewing the file logs/server.log. After changing my password, I could still see the old password in the logs. Same with the change of the mongo_host, post change, was still the first instance/IP I tried.
2) If your password contains an '@' symbol, or something that doesn't URL encode properly, you'll need to submit the pwd in URL encode format (as it notes in the community app)
I ran into this and changing the pw from one with an @ , and recreating the container to a NEW appdata path (unifinetworkapplication versus unifi-network-application) resolved for me