Home >Web Front-end >JS Tutorial >IIS extension iisnode installation and configuration notes for running Node.js_node.js
At the beginning of this year, I planned to use Node.js to rewrite the blog program based on the Express framework and say goodbye to ASP.NET. However, the VPS I am currently using is a Windows Server system and an IIS server. If both Express and IIS are allowed to listen to port 80, there will obviously be a conflict. Fortunately, there is an extension called iisnode that can host Node.js programs on IIS. Moreover, such hosting also means that you can use various functions in IIS (process management, GZip compression, logs, cache, permission control, domain name binding, etc.).
To use iisnode, you must install:
1.Node.js
2.URL Rewrite module of IIS
3.iisnode
After installation, follow the usual operations and create a site in the IIS manager, pointing to the directory of the Express program. The key is to add a web.config file:
in
There is a configuration in Web.config (added before ) that can retain REMOTE_ADDR:
Copy code
Copy code
Copy code