I have react app and nodejs api server. React app make fetch requests to nodejs server. React app and nodejs server deployed in own containers.
The problem is I can access nodejs server directly in browser, so is there way to 'hide' nodejs backend server, and let access only through frontend.
It should work something like this
- React app make fetch request
- nginx intercept request and forward to nodejs server
- nodejs handles request
I think it can be done with nginx reverse proxy or docker networks or somehow...