I'm developing a web app composed by Express js as backend and Vue js as frontend. Until I worked on local lan in development mode I was able to access both of them using different ports, but now that I want to make a release and open it to external connections I don't know how to do that.
In particular I opened the two ports in my lan firewall (Pfsense), respectively 4000 for backend and 5000 for frontend (random numbers, there is no particular reason why I chose them) and from outside I can reach both of them separately, as follows:
myPublicIp:4000 --> I get all the answers from backend api
myPublicIP:5000 --> I get the frontend interface
The problem is that when I load frontend, the backend related data are not loading. How is that possible? Is it a firewall problem or am I missing something in the webapp?