please before to mark this as duplicated read my own case, it’s a bit different from others.
I’m developing multiple node.js endpoints that I’d like to have under the same domain.
These services do respond to something like:
/user/:user_id/authorization– base path for the authorization service/user/:user_id/log– base path for the log service
And so on.
The first part /user/:user_id/ is the same to all services, it’s just a REST way to pass the user id inside the path instead of using the Authentication header.
Is there a way I can reverse-proxy NGINX to these webservices since they are using the same base path?
Another question: if NGINX is not used for caching content, may it downgrade node.js performances (for example if its performances are worst than node.js) if it’s reverse proxying?
With nginx you can do whatever routing you want, look here as a start point: http://nginx.org/en/docs/http/request_processing.html and http://nginx.org/r/location
node.js itself or nginx frontend for serving static files?
Also see: http://www.aosabook.org/en/nginx.html