Bind Node.js app from Port to Web Address

1 post / 0 new
#1 Sun, 05/27/2018 - 19:45
rfarin

Bind Node.js app from Port to Web Address

Hi,

I have a nodejs app installed over at /home/username/public_html/OS.js and by running "$ node osjs run" on ssh it starts a server over at http://localhost:5000

After opening the 5000 port on FirewallD, when I go to localhost:5000 I can access the app, but when I go to https://website.com/OS.js/ , I'm not able to access it.

So, I would like to ask for some guidance on how to bind a port to a web address page folder, so it redirects the port to my website. I have both Webmin and Virtalmin installed, is it easier to setup over webmin or ssh?

I know I have to configure a Reverse-Proxy but I'm a bit lost on where and how to do this. I'm running a CentOS 7.5 cloud server with apache web server.

Thanks in advance.