Need help setting up SSL and ports

October 5, 2016 121 views
Security Node.js Ubuntu 16.04

Hello guys, I need your help thinking a solution for my problem. I'm using two meteorJS apps on my droplet, one on port 80 (ssl 443) and the other one on port 420. I need to setup SSL for the 420 port app. I can't use port 443 because it's already bound to the first app. I'm using Meteor-UP to deploy to my droplet.
Any ideas?

3 Answers

Hi there,

Don't run your applications directly on ports 80 and 443, use a web server, I recommend Nginx! Run your apps on random ports and then setup Nginx to listen on 80 and 443, and configure it to route the traffic to your applications. You can find very good tutorials on how to setup and configure Nginx on your droplet in the community!

Good luck!

  • Hello Youssef, thanks for your reply. I'm not using Nginx, but Meteor-UP. Meteor-UP internally uses Nginx but iḿ not sure if I can modify it's settings. I'll check.

    • I tried to see if there's a way to configure Meteor-Up and found this on the GitHub page:

      Multiple Deployments

      Meteor Up supports multiple deployments to a single server. Meteor Up only does the deployment; if you need to configure subdomains, you need to manually setup a reverse proxy yourself.

      So I think you really should use Nginx, or another web server in front of it!

for meteoar app you need to run

meteor npm install --save bcrypt 


sudo meteor --port 80

or any port you need

change port in default config

Have another answer? Share your knowledge.