dciancu / unifi-protect-unvr-docker-arm64

UniFi Protect UNVR Docker container for arm64
https://hub.docker.com/r/dciancu/unifi-protect-unvr-docker-arm64
29 stars 0 forks source link

404 When Attempting to Connect for First Time Set Up #4

Closed npaolini-8 closed 4 months ago

npaolini-8 commented 4 months ago

Thanks so much for this project: When attempting to run this container for the first time I'm getting a 404 when attempting to get into the web interface. Hardware: pi5 running ubuntu 23.10

Recapping steps:

  1. pulled down the repo, stable version, did not edit any files
  2. created docker-compose.override.yml, specifying my directory for saving + timezone
  3. disconnected server from the internet
  4. ran docker compose up -d
  5. verified that the web interface launched via docker compose logs
  6. attempted to connect to the web interface at https://<server ip>:7443-> was prompted that this was an unsafe connection, proceeded -> redirected to <server ip>/protect with a 404
  7. restarted the service with docker compose restart
  8. attempted to connect again with the same result, no cert prompt

I also tried connecting to http://<server ip> as mentioned in the README, but that connected me to the lighttpd placeholder page

Please let me know if I made any silly mistakes or what logging information you may want. I did see a postgres failure, but it looked like it resolved

dciancu commented 4 months ago

Hi, First of all, the port for accesing Protect is the default 443 (https://<server ip>) after the initial setup, and 80 (http://<server ip>) during the initial setup.

Your steps are correct, except for step 6, you should navigate to http://<server ip> and see the following: Screenshot 2024-06-07 at 12 08 22

Make sure the server IP you are connecting to is correct, and that no other services on the host are interfering, because lighttpd is not from this image, as Protect uses nginx. Post an image of what you are seeing when accesing http://<server ip>.

Check with docker compose logs that you see the following:

[  OK  ] Started nginx - high performance web server.
[  OK  ] Started ULP-GO.
[  OK  ] Started UniFi Core.
[  OK  ] Started UniFi Protect.
npaolini-8 commented 4 months ago

Thanks, you pointed me in the right direction, lighttpd for Pi-Hole web-ui was trying to serve on the same port as nginx, I switched the port for the lighttpd service from 80 to 82, and I can access the console now. Unfortunately now I'm contending with two new problems:

1: image Console is saying no HDD detected, is this expected? I tried with and without an override for STORAGE_DISK

2: my camera isn't showing up for adoption. The camera has an IP, I can connect to it directly and am greeted with a Unifi Protect log in screen, but I'm unable to see it in the device list, despite checking all the filter boxes. I briefly saw a pop-up saying a camera was available for adoption, but nothing in the list when I went to look. I don't think this is an image issue, but if you had any tips I'd appreciate it.

dciancu commented 4 months ago

The HDD problem means most likely you did not set STORAGE_DISK value correct, for Raspberry Pi it should be /dev/mmcblk0p2. In regards to the camera not showing up for adoption, make sure your docker host is on the same subnet as the camera, try to ping the camera from the docker host. Also, reset the camera and try again.

npaolini-8 commented 4 months ago

Thanks for your help! Ended up being nvme0nlp2. Adopting still not working, but will work on it.