Hello all. Stuck trying to setup up several Node apps on one droplet. I followed the Host Multiple Node.js Applications On a Single VPS with nginx, forever, and crontab article exactly.
I have the domains all pointed correctly and A records set.
I can’t seem to get apps to run (with forever) on any other port besides the default express 3000.
I changed the server_names_hash_bucket_size 64; (like it says) I created /etc/nginx/conf.d/example.com.conf for the apps (they are different domains. I put 1 on port 3000 and the other on 4000)
I don’t understand the difference between when Nginx is running the app and when forever is? Where does “npm start” come into play? How many potential servers are working at the same time?
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Click below to sign up and get $100 of credit to try our products over 60 days!