Question

I've installed Node.js on my DreamHost VPS (basically a virtual machine), but my VPS hosts a lot of other websites using Apache. How can I bind an HTTP listener to a specific domain using Node.js, so that when I visit "mynodejsdomain.com", I get responses from my Node.js code, but when I visit "myotherdomain.com", I get responses from Apache/PHP?

Was it helpful?

Solution

Turns out I needed to tell Apache to forward the requests for that domain, and DreamHost provides a nice frontend for mod_proxy:

http://wiki.dreamhost.com/Proxy_Server

Thanks, CodeCaster!

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top