不能监听80端口
2018-07-31 本文已影响0人
围观工程师
报错
Port 80 requires elevated privileges
原因
in Linux (and Mac OS X) port 80 is reserved for system administrators (root user). As this post on serverfault indicates, this is true for any port below 1024.
解决办法
A quick way around this problem is to run node webserver.js as a root user via sudo