(Solved) Unable to connect Unifi AP AC LR directly to SG-5100 and I have no hair left because of it

Im redoing my entire network and have a Netgate SG-5100, 2 Unifi AP AC LR’s and a linksys 8-port ethernet switch. I want IX0 to have one of the APs connected directly to it for all my wireless devices downstairs and IX1 to have the switch and other AP for my upstairs office and wireless devices up there. Both IX’s work fine with the or direct connect to a laptop however the AP’s wont show up in the unifi controller. When I connect them to the switch the show up just fine. What am I doing wrong? Only firewall rules are allow all traffic right now

Make sure you don’t have a double NAT, double firewall or double dhcpd.

Also make sure you have spanning tree protocol enabled if you are using one of the AP’s as a repeater.

You also need to create an interface for your switch on the AP that is going to use it, if you are using a VLAN.

Otherwise you need to tag the port for your switch with the processor of the AP.

All of this is a lot more straightforward to do on OpenWRT imo

Check to make sure the IP address you are getting for the access point is accessible from the UniFi controller.

A user over at the Netgate Forums named Bingo600 suggested
My guess is that you have the Unifi controller connected to the same network as the “switch network” , then the AP can find the controller by broadcast.

You need to “help” the AP’s not on the Controller network , by setting the unifi dns name to point to the controller host.

I have this in my Services → DNS Resolver “Customs options” , where a.b.c.d is my controller ip address

local-data: "unifi.<your-domainname> A a.b.c.d

Solved the issue instantaneously. Thanks all and Hi Tom love the videos btw