Node.js Server running from a sub folder

后端 未结 3 1409
伪装坚强ぢ
伪装坚强ぢ 2021-02-07 18:41

So I\'m pretty late to the Node.js party. Mainly because nobody invited me... Thanks. That said, I\'m starting to work it out. I have come from an ASP classic b

3条回答
  •  刺人心
    刺人心 (楼主)
    2021-02-07 19:06

    Only one server can listen on a port at a time. You cannot have Node.js and some other server on the same port.

    The best thing to do is set up a different hostname for your other server.

    If you cannot do that, the standard way is to proxy requests from one server to the other. This is relatively easy to do, but you didn't specify what server you're running, so it is impossible to be more specific.

提交回复
热议问题