Reputation: 73
I followed the instruction to make my nodejs server listening to port 80.
My server does not have a domain yet. The problem is that if my server used HTTPS
, I cannot access my server without specifying port 80 like this https://xx.xxx.xxx.xx:80
. However, using HTTP
, without specifying port, I still can access my website using IP.
What did I do wrong here?
Upvotes: 2
Views: 2568
Reputation: 1
you can find the default port of a certain service in file /etc/services, If the server do not use these default ports, then you have to specify the port as you said to browse.
Upvotes: 0
Reputation: 5516
Because the default port for https connections is 443. So browsers will connect on that default port if your url has a https protocol and no port number specified.
Since you are using port 80 (which is the default port for plain http), you need to specify the port number in your URL.
In short, you need to specify the port number in your URL if your server is listening on a port other that the default port for that protocol.
Upvotes: 4