I am trying to configure a reverse proxy so that HTTP calls made from a website hosted in the IIS to node.js applications work.
I'll explain it better:
I've hired a VPS. In this VPS i have a IIS website (simple HTMl + Javascript ) and a node.js application running on localhost:3000. In javascript i make HHTP GET calls to the node.js to obtain some data.
I need to configure a reverse proxy so that the HTTP calls made to node.mydomain.com for example, are internally redirected to localhost:3000.
Example of website's HTTP call:
$.get( "node.mymydomain.com/balance", function( data ) {
alert( data );
});
After 2 days fighting with IIS, ARR and URL rewrite i am not able to configure it properly and i believe it is not so complicated...
It's the first time i'm using IIS and i need some tips or tutorial...
This is what i've done so far:
- I created a server farm called "node" pointing to 127.0.0.1 and in advanced setting i change the HTTP port from 80 to 3000 because that's where my node.js app is running:
- I am asked if i want to create a URL Rewrite Rule i click on Yes:
- I generate the following Condition:
I add the condition and Route it to my new "node" server farm:
I test on my laptop node.mydomain.com/balance and it is not working.... :S
I really would appreciate some help with this..
Regards,