PfSense and HAproxy without expolse my backend API

Hi, i use haproxy with pfsense, for my website my reverse proxy work perfect, but when i try to make a login from my website that not working. This validation it is in another machine (backend API). One machine for my http server and another for backend API. The HttpServer make access to my Backend. Nothing especial with that!! But this access, not work untin i have to expolse my backend API and i don’t want that. It is possible this work without expolse my API’s? This configuration it is in HAproxy? When i say expolse it is on my domain server and create a DNS A record with my hostname and public ip. This hostname it is the same on my local machine.

I am not really clear on the what you are trying to achieve but there is some filtering you can do in HAproxy to block access to specific resources but it might be even better to do so in the app it’s connecting to.

Hi, thanks, i just want access by my website my backend api without try to resolve outside my network.

If call my backend like this, or first try to resolve outside, and i don’t want that.