Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to use iis deployment in Node.js to run node

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/03 Report--

This article introduces how to use iis in Node.js to deploy and run node, the content is very detailed, interested friends can refer to, hope to be helpful to you.

It's a long story about the migration of linux to windows server. It is said on the Internet that iis already supports node. IIS Node tossed about for a while, did not run, it is estimated that the compatibility is not so good, just give up. Directly deployed by pm2.

IIS Node address: https://github.com/tjanczuk/iisnode/wiki/iisnode-releases

IIS UrlRewrite address: https://www.iis.net/downloads/microsoft/url-rewrite is installed

Create a web.config in the root directory of the site, as follows

There are three rules, the first one is the forwarding of https

The second and third, respectively, forward all sources from the master record (chuchur.com) and aliases (www.chuchur.com) to the node port.

What's left is a SPA documentation site (vue).

There are two rules together, the first of which is a proxy that forwards / rest/ to / rest/ on the node port. The second is the address Rewrite of the vue routing history mode

On how to use iis deployment in Node.js to run node to share here, I hope the above content can be of some help to you, can learn more knowledge. If you think the article is good, you can share it for more people to see.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report