Search code examples
phpnode.jsnginxreverse-proxynginx-reverse-proxy

How to run my node app alongside my php application


I've been playing around with nginx and reverse proxy's to try figure out how to run my nodejs app alongside my php application. The node app is just a simple socket io chat app but i'd like it to run on chat.mydomain.com. Would someone be able to guide me in the right direction?

Thanks


Solution

  • You are looking for NGINX server blocks. You can create one proxy for your php app on yourdomain.com and another one for chat.yourdomain.com which points to your node app.