尝试使用IISNode在Windows IIS中托管应用程序时,我遇到以下错误。
iisnode在处理请求时遇到错误。
HRESULT: 0x2
HTTP status: 500
HTTP subStatus: 1002
HTTP reason: Internal Server Error
You are receiving this HTTP 200 response because
system.webServer/iisnode/@devErrorsEnabled configuration setting is 'true'.
In addition to the log of stdout and stderr of the node.exe process,
consider using debugging and ETW traces to further diagnose the problem.
The last 64k of the output generated by the node.exe process
to stderr is shown below:
在Object.fs.lstatSync(fs.js:893:18)
在Object.realpathSync(fs.js:1527:21)
在Function.Module.\u findPath(Module.js:180:22)
在Function.Module.\u解析文件名(Module.js:470:25)
at Module.require(Module.js:500:17)
根据需要(内部/module.js:20:19)
我已尝试将服务器更改为侦听
process.env.PORT
我仍然有问题。
<rewrite>
<rules>
<rule name="sendToNode">
<match url="/*" />
<action type="Rewrite" url="server.js" />
</rule>
</rules>
</rewrite>
<iisnode
nodeProcessCommandLine=""%programfiles%\nodejs\node.exe""
interceptor=""%programfiles%\iisnode\interceptor.js""
/>
在
web.config