-1

I have tried everything searching for this errors solution for weeks now, still stuck at it. I have tested this nodejs api on test enviroment IIS before its working fine on that, but when i try to deploy it on main iis live server its giving me this error: enter image description here

When i try to browse the directory on url it shows the directory correctly: enter image description here

My web config:

<configuration>
  <system.webServer>
      <iisnode node_env="%node_env%"
                 nodeProcessCountPerApplication="1"
                 maxConcurrentRequestsPerProcess="1024"
                 maxNamedPipeConnectionRetry="100"
                 namedPipeConnectionRetryDelay="250"
                 maxNamedPipeConnectionPoolSize="512"
                 maxNamedPipePooledConnectionAge="30000"
                 asyncCompletionThreadCount="0"
                 initialRequestBufferSize="4096"
                 maxRequestBufferSize="65536"
                 uncFileChangesPollingInterval="5000"
                 gracefulShutdownTimeout="60000"
                 loggingEnabled="true"
                 logDirectory="iisnode"
                 debuggingEnabled="true"
                 debugHeaderEnabled="true"
                 debuggerPortRange="5058-6058"
                 debuggerPathSegment="debug"
                 maxLogFileSizeInKB="128"
                 maxTotalLogFileSizeInKB="1024"
                 maxLogFiles="20"
                 devErrorsEnabled="true"
                 flushResponse="false"
                 enableXFF="false"
                 promoteServerVars=""
                 configOverrides="iisnode.yml"
                 watchedFiles="web.config;*.js"
                 nodeProcessCommandLine="C:\Program Files\nodejs\node.exe"/> 
    <handlers>
      <add name="iisnode" path="app.js" verb="*" modules="iisnode" />
    </handlers>
     <rewrite>
       <rules>
         <rule name="api">
           <match url="api*" />
           <action type="Rewrite" url="/mynode/app.js" />
         </rule>
       </rules>
     </rewrite>  
      <security>
       <requestFiltering>
         <hiddenSegments>
           <add segment="node_modules" />
         </hiddenSegments>
       </requestFiltering>
     </security>
        <directoryBrowse enabled="true" />


  </system.webServer>

</configuration>

I have already tried to look at the log files but it cant provide the details of the error, the same thing working fine in test enviroment. Is there any way i can see the complete error message or the solution of this error.

1 Answers1

1

You can use failed request tracking to view detailed error information.

More information about how to use failed request tracking you can refer to this link: Using Failed Request Tracing to Trace Rewrite Rules.

samwu
  • 3,857
  • 3
  • 11
  • 25