GithubHelp home page GithubHelp logo

azure / iisnode Goto Github PK

View Code? Open in Web Editor NEW

This project forked from tjanczuk/iisnode

654.0 66.0 101.0 8.62 MB

Hosting node.js applications in IIS on Windows

License: Other

C++ 76.47% C 0.16% JavaScript 14.75% HTML 4.43% CSS 0.11% Batchfile 3.79% Pug 0.29%

iisnode's Introduction

Hosting node.js applications in IIS on Windows

Branches

  • master: stable version.
  • iisnode-dev: development branch.

Why would I want to do it?

Benefits

Who uses iisnode?

Prerequisites for using

Installing for IIS 7.x/8.x

  • Install iisnode for IIS 7.x/8.x: x86 or x64 - choose bitness matching your system
  • To set up samples, from the administrative command prompt call %programfiles%\iisnode\setupsamples.bat
  • Go to http://localhost/node

Installing for IIS Express/WebMatrix

  • Install WebMatrix using the Web Platform Installer
  • Open WebMatrix, choose “Site from folder”, enter %localappdata%\iisnode\www, start the site, and play with the iisnode samples, or
  • Use node.js templates to get started quickly with an Express application or a skeleton Hello World

Installing for IIS Express 8 on Windows x64 This can be a head-scratcher since IIS Express 8 gives you both 32-bit and 64-bit versions (http://www.iis.net/learn/extensions/introduction-to-iis-express/iis-80-express-readme). You can either:

  • Install the full x64 version, then in Visual Studio go to Tools > Options > Projects and Solutions > Web Projects > Use the 64 bit version of IIS Express. This way you have a single install for both IIS and IIS Express.
  • Separately install iisnode express version (https://github.com/azure/iisnode/wiki/iisnode-releases).

Howtos

Prerequisites for building

Building

Build commands should be issued from the build environment set up with "%programfiles(x86)%\Microsoft Visual Studio 11.0\Common7\Tools\VsDevCmd.bat", assuming default installation location of Visual Studio 2012 on x64 platform.

For x86 build:

msbuild /p:Platform=Win32 src\iisnode\iisnode.sln

For x64 build:

msbuild /p:Platform=x64 src\iisnode\iisnode.sln

Installing after build

  • For IIS 7.x/8.0: build\debug\{x64|x86}\iisnode-full.msi
  • For IIS Express 7.x: build\debug\x86\iisnode-express.msi

Running tests

  • Install for IIS 7.x/8.x (see previous sections)
  • test\functional\test.bat
  • note that for the WebSocket tests to pass you must be running in IIS 8.x on Windows 8 or Windows Server 2012

Resources & documentation

iisnode's People

Contributors

avanderhoorn avatar davidebbo avatar dpolivy avatar jennylawrance avatar mattezell avatar maxmalov avatar microsoft-github-policy-service[bot] avatar paulinetheitgirl avatar pmanijak avatar pofallon avatar purva-vasudeo avatar rramachand21 avatar rramachand21-zz avatar tjanczuk avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

iisnode's Issues

IPv4/6 issue

Hi,
i’m using nodejs on Azure websites and i’m trying to geolocate users using the IP that iisnode add to req.headers['x-forwarded-for'].
From what I can see, IP’s are passed in different ways:
-most of the time everything is correct: xxx.xxx.xxx.xxx:PORT
-sometimes I see: xxx.xxx.xxx.xxx, xxx.xxx.xxx.xxx:PORT (which one is the correct one?)
-and others are: unknown, xxx.xxx.xxx.xxx:PORT (why is this IP unknown?).

And what about IPV6?
How do IIS manage them inside req.headers['x-forwarded-for']?
What happens if there are more than 2 IPV6?

DO you think is possibile to separate IP from PORT (maybe adding another X-Header just for the port?)
Thank you.

Sporadic crashs / heap failures

In high-pressure tests the w3wp process will sporadically crash in IISNode.
The system is windows 10, node 7.4, iisnode 0.2.26 (x64)

While processing the response from node, calling httpCtx->GetResponse()->Clear() triggers a heap failure.
The heap failure is a use after free, the heap was already cleared.

Currently running in the response callback of node we can see from the storedCtx that m_cRefs = 1, thus the CleaupStoredContext must have been called, decrementing m_cRefs and making the IHttpContext invalid. Sometimes the response will break in ProcessChunkHeaders because the header is invalid, sometimes because the broken pipe error code is already set.
The assumption is that the request gets closed from client side while the node response is still running.
Looks like access to IHttpContext has to be prevented after CleanupStoredContext has been called.

Unhandled exception at 0x00007FFB65E48283 (ntdll.dll) in w3wp_exception.dmp: 0xC0000374: A Heap has been corrupted (parameters: 0x00007FFB65E9F6B0).

           ntdll.dll!RtlReportCriticalFailure ()            Unknown
           ntdll.dll!RtlpHeapHandleError ()  Unknown
           ntdll.dll!RtlpLogHeapFailure ()    Unknown
           ntdll.dll!RtlFreeHeap ()   Unknown
           iiscore.dll!W3_RESPONSE::ClearEntity(int)         Unknown
           iiscore.dll!RESPONSE_CONTEXT::Clear(void)    Unknown
           iisnode.dll!CProtocolBridge::SendEmptyResponse(IHttpContext * httpCtx, unsigned short status, unsigned short subStatus, const char * reason, HRESULT hresult, int disableCache) Line 468      C++
           iisnode.dll!CProtocolBridge::SendSyncResponse(IHttpContext * httpCtx, unsigned short status, const char * reason, HRESULT hresult, int disableCache, const char * htmlBody) Line 451       C++
           iisnode.dll!CProtocolBridge::SendDevError(CNodeHttpStoredContext * context, unsigned short status, unsigned short subStatus, const char * reason, HRESULT hresult, int disableCache) Line 398          C++
           iisnode.dll!CProtocolBridge::SendEmptyResponse(CNodeHttpStoredContext * context, unsigned short status, unsigned short subStatus, const char * reason, HRESULT hresult, int * pfCompletionPosted, int disableCache) Line 424   C++
           iisnode.dll!CProtocolBridge::ProcessChunkHeader(unsigned long error, unsigned long bytesTransfered, _OVERLAPPED * overlapped, int * pfCompletionPosted) Line 1642        C++
>          iisnode.dll!CAsyncManager::Worker(void * arg) Line 193 C++
           iisnode.dll!invoke_thread_procedure(unsigned int(*)(void *) procedure, void * const context) Line 92         C++
           iisnode.dll!thread_start<unsigned int (__cdecl*)(void * __ptr64)>(void * const parameter) Line 115 C++
           kernel32.dll!BaseThreadInitThunk ()         Unknown
           ntdll.dll!RtlUserThreadStart ()      Unknown

Content of storedCtx variable:

-                       storedCtx          0x000001ba37ccfbe0 {activityId={B93342A8-234F-46D6-97A0-E0C5EC52BF86} nodeApplication=0x000001ba36c4f7a0 {...} ...}    CNodeHttpStoredContext *
+                      IHttpStoredContext        {...}       IHttpStoredContext
+                      activityId           {B93342A8-234F-46D6-97A0-E0C5EC52BF86}     _GUID
+                      nodeApplication            0x000001ba36c4f7a0 {scriptName=0x000001ba36c396c0 L"C:\\Program Files\\Siemens\\Automation\\WinCCUA\\WebRH\\server.js" ...}     CNodeApplication *
+                      context 0x000001ba38c581e0 {...}          IHttpContext *
+                      asyncContext    {overlapped={Internal=3221225803 InternalHigh=0 Offset=0 ...} completionProcessor=0x0000000000000000 ...}  ASYNC_CONTEXT
+                      process            0x000001ba36386a80 {processManager=0x000001ba36bdff70 {application=0x000001ba36c4f7a0 {scriptName=0x000001ba36c396c0 L"C:\\Program Files\\Siemens\\Automation\\WinCCUA\\WebRH\\server.js" ...} ...} ...}       CNodeProcess *
                        pipe      0xffffffffffffffff void *
                        connectionRetryCount   0          unsigned long
                        buffer   0x000001ba38c59150    void *
                        bufferSize         4096     unsigned long
                        dataSize           2          unsigned long
                        parsingOffset    0          unsigned long
                        chunkTransmitted          2779     __int64
                        chunkLength     1394     __int64
                        isChunked         1          int
                        result    0x0000000b : Es wurde versucht, eine Datei mit einem falschen Format zu laden.             HRESULT
                        requestNotificationStatus           RQ_NOTIFICATION_FINISH_REQUEST (2)            REQUEST_NOTIFICATION_STATUS
                        pendingAsyncOperationCount    0          volatile long
+                      targetUrl            0x000001ba38c58ba0 "/WebXX/socket.io/?EIO=3&transport=polling&t=Li03Ljz"   const char *
                        targetUrlLength  70         unsigned long
+                      childContext      0x0000000000000000 <NULL>    IHttpContext *
                        isLastChunk      0          int
                        isConnectionFromPool  1          int
                        expectResponseBody   1          int
                        closeConnection           0          int
                        isUpgrade         0          int
+                      upgradeContext            0x0000000000000000 <NULL>    CNodeHttpStoredContext *
                        opaqueFlagSet 0          int
                        requestPumpStarted      0          int
+                      startTime           {dwLowDateTime=3647056925 dwHighDateTime=30581902 }       _FILETIME
+                      responseChunk {DataChunkType=HttpDataChunkFromMemory (0) FromMemory={pBuffer=0x000001ba37eb53c0 BufferLength=1387 } ...}    _HTTP_DATA_CHUNK
                        responseChunkBufferSize          4096     unsigned long
+                      eventProvider    0x000001ba378950c0 {handle=16890397897277296 advapi=advapi32.dll!0x00007ffb65b30000 {unused=9460301 } ...}   CNodeEventProvider *
                        m_cRefs           1          long

How to upgrade iisnode?

I have an older version of iisnode running on a Windows Server. How do I upgrade it to latest version?

I searched but couldn't find any info on upgrading iisnode.

Can't install at Windows 10

display 'iis7.x or later must be installed before iisnode installation' when run iisnode-full-v0.2.11-x64.msi at windows 10 Home

access to binding config

By inspecting the ENV, http-request object and iisnode extra headers that could be added, in an index.js within an iisnode-nodejs instance, it does lack the binding data.
Original host and port used. As well as any configured IIS site binding,

Is there a workaround for it?

iisnode encountered an error when processing the request.

it is working fine on my windows 10 with iis 10 but when i deploy to windows server 2012 R2 with iis 8 i am getting the following error

iisnode encountered an error when processing the request.
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 node.exe process has not written any information to stderr or iisnode was unable to capture this information. Frequent reason is that the iisnode module is unable to create a log file to capture stdout and stderr output from node.exe. Please check that the identity of the IIS application pool running the node.js application has read and write access permissions to the directory on the server where the node.js application is located. Alternatively you can disable logging by setting system.webServer/iisnode/@loggingEnabled element of web.config to 'false'.

child_process.fork() fails with process exit error code 1 but no other information available

I am encountering a strange issue with iisnode on Azure. Basically, the issue is child_process.fork() seems to not work and doesn't throw errors. I've tried attaching to the uncaughtException event, combing the logs, and so on -- but the only information I get is from the "exit" process event and the error code is 1, which means uncaught exception. No other information is available. For the .js file that I am forking, I can run it manually with the exact same command line in the Kudu command line prompt and it runs fine. But when executed via child_process.fork(), I don't even see the initial console.log() statement execute. I know the child process is being spawned because I can see it in the Kudu process list with the proper command line and with access to all the same environment variables, and so on. I am using the latest version of node.exe which is 8.8.4, though initially it was running on whatever the default version was when I setup the original stub template in Azure (node 4.2.4).

Does anyone have thoughts as to what might be going on?

Here's my web.config:

<system.web>
    <customErrors mode="off" />
</system.web>

<system.webServer>
    <httpErrors existingResponse="PassThrough" />

    <handlers>
        <!-- indicates that the app.js file is a node.js application to be handled by the iisnode module -->
        <add name="iisnode" path="index.js" verb="*" modules="iisnode" />
    </handlers>

    <rewrite>
        <rules>
            <!-- Don't interfere with requests for logs -->
            <rule name="LogFile" patternSyntax="ECMAScript" stopProcessing="true">
                <match url="^[a-zA-Z0-9_\-]+\.js\.logs\/\d+\.txt$" />
            </rule>

            <!-- Don't interfere with requests for node-inspector debugging -->
            <rule name="NodeInspector" patternSyntax="ECMAScript" stopProcessing="true">                    
                <match url="^index.js\/debug[\/]?" />
            </rule>
          
            <!-- First we consider whether the incoming URL matches a physical file in the /public folder -->
            <rule name="StaticContent">
                <action type="Rewrite" url="public{REQUEST_URI}" />
            </rule>

            <!-- All other URLs are mapped to the Node.js application entry point -->
            <rule name="DynamicContent">
                <conditions>
                    <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="True" />
                </conditions>
                <action type="Rewrite" url="index.js" />
            </rule>
        </rules>
    </rewrite>
    
    <iisnode
      loggingEnabled="true"
      devErrorsEnabled="true"
     />

</system.webServer>

Support Meteor projects

Currently there is no real way of deploying METEOR projects to windows world.
Would be great if IISNODE would support them out of the box.

Request: Documentation Update for Debugging

Currently, many users are finding it difficult to work with IISNode for a number of reasons.

One of the reasons users are experiencing problems is as a result of the fragmentation created by the original (no longer maintained) repo not directing users to this repo. In hopes of making this a bit better, I've reached out to the author on Twitter to see if he'd consider updating the readme to do that. I chose to reach out on Twitter because it seems that the author is active there, while no longer replying to issues in the original repo.

Another problem is the accuracy of the documentation - including documentation in this Azure repo. For example, the "NEW: integrated debugging with node-inspector v0.7.3" link takes you to a product sales site, which does not instill confidence in users when they find themselves referencing the IISNode documentation here in the official Azure repo.

Something else that would improve user's experiences would be to update the documentation with updated debugging guidance. For example, I've successfully setup debugging in VSCode against an IISNode hosted NestJS/Express application, as I've detailed here: #54 (comment) I would propose this be included in the documentation. I would be happy to write this process up more formally if that would be of assistance to this project.

iisnode failed to initialize a new node.js application

Placing the helloworld demo in a subfolder of an existing site gives me 'HTTP Error 500.1000 - Internal Server Error'

Traces show three errors -
iisnode failed to initialize a new node.exe process
iisnode failed to initialize a new node.js application
iisnode failed to create a new node.js application

Module
iisnode
Notification
ExecuteRequestHandler
Handler
iisnode
Error Code
0x8007000d

If I create a new website and use the same AppPool, it works.

Hello, world! [helloworld sample; iisnode version is 0.2.21, node version is v11.8.0]

Anyone have any ideas? I've checked permissions, but can't seem to get anything to work when it's in our existing website. If I run ProcMon on the working site, I see it spawn the node.exe processes. It isn't spawning the process on the failed site, but I see no logged failed attempts.

nodeProcessCommandLine is the same for both sites.

Does not recognize IIS 10 on Win 2016

The most compatible MSI I could find was iisnode-full-iis7-v0.2.2-x64.msi but when I ran it on Windows Server 2016 with IIS 10.0.14393.0 (tested, working), I got a 'You must have IIS installed first'.

Is there an MSI / BInary that'll run on Win Server 2016 / IIS 10?

HTTP Error 500 with substatus 1011/1013 and win32 error 109 (ERROR_BROKEN_PIPE)

On some of our servers our users are experiencing occasional internal server errors which we are unable to explain. According to our logs some requests fail with a broken pipe, but these requests are no different from other requests which work fine. We have now implemented a retry-mechanism, and so far requests that failed do work on the first retry. This seems to confirm that there is nothing 'wrong' with the requests themselves.

We have tried to create a minimal example (see files below), and performed some tests:

Node version IISNode version NODE_PENDING_PIPE_INSTANCES Result
7.3.0 0.2.18.0 Undefined Works (in practice). There are no errors, at least long as there are not "too many" concurrent requests. However, when it fails, it fails with error 500.1003 (which is a different error, which we have not seen, "The service is unavailable"). The number of concurrent requests needed to cause this is sufficiently large that we don't expect to have hit this in practice.
9.3.0 0.2.18.0 Undefined Error 500.1011 / 500.1013 on some requests.
10.7.0 0.2.18.0 Undefined Error 500.1011 / 500.1013 on some requests.
7.3.0 0.2.21.0 5000 Works perfectly. I get errors on my PC (regarding fork limit) before the server starts to give error 500s.
9.3.0 0.2.21.0 5000 Error 500.1011 / 500.1013 on some requests.
10.7.0 0.2.21.0 5000 Error 500.1011 / 500.1013 on some requests.

I used the following minimal example, on an up-to-date Windows Server 2016 Version 1607 (OS Build 14393.2248) installation with IIS (Version 10.0.014393.0). The below files were placed in C:\Error1013. In this directory I placed 3 node executables with different versions (see above table). On a different PC we
run the 'poll.sh' script to test concurrent requests.

The example web server is very simple, and consists only of a short delay (1/8th of a second) in order to simulate processing time otherwise taken by our service.

It is our understanding that with NODE_PENDING_PIPE_INSTANCES set to the default value of 5000, we should not run into resource limits regarding concurrent requests until we reach 5000 concurrent requests. However, are getting error 500.1013 / 500.1011 with as few as 50 concurrent requests. Is this a known issue (e.g. #50)? In our case it does not seem to be related to the processing time of a request, as each simulated request takes only 1/8th of a second.

web.config
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
	<system.webServer>
		<iisnode nodeProcessCommandLine="C:\Error1013\node_10.7.0.exe"
			loggingEnabled="true"
			devErrorsEnabled="false"
			enableXFF="true"
			promoteServerVars="HTTP_URL"
			logDirectory=".\logs"
		/>
		<handlers>
			<add name="iisnode" path="hello.js" verb="*" modules="iisnode" />
		</handlers>
		<rewrite>
			<rules>
				<rule name="nodejs">
					<match url=".*" />
					<action type="Rewrite" url="hello.js" />
				</rule>
			</rules>
		</rewrite>
	</system.webServer>
</configuration>
package.json
{
	  "name": "my-awesome-package"
	, "version": "1.0.0"
	, "main": "hello.js"
	, "dependencies": {
		"http": "*"
	   }
}
hello.js
var http = require('http');
const util = require('util');

var seconds = 0.125;

var startUp = new Date();

http.createServer((req, res) => {
	res.writeHead(200, {'Content-Type': 'text/plain'});
	var waitTill = new Date(new Date().getTime() + seconds * 1000);
	while(waitTill > new Date()){}
	res.end(`${startUp} process.env.NODE_PENDING_PIPE_INSTANCES: ${process.env.NODE_PENDING_PIPE_INSTANCES}\n`);
}).listen(process.env.PORT);
poll.sh
#!/bin/sh

server=192.168.22.254:8080

# This breaks sometimes, but not very often
concurrent_requests=30
inter_request_delay=0.05

# This breaks almost every time
concurrent_requests=50
inter_request_delay=0.01

# # We've gotta push it harder!
# concurrent_requests=250 # 500 gives fork error on my pc
# inter_request_delay=

while true ; do
	echo "Press <enter> to send ${concurrent_requests} requests (delay: ${inter_request_delay:-none})..."
	read l
	i=0; while [ ${i} -lt ${concurrent_requests} ] ; do
		curl "${server}" &
		i=$((i+1))
		[ -n "${inter_request_delay}" ] && sleep ${inter_request_delay}
	done
	# concurrent_requests=$((concurrent_requests+10))
	echo "Waiting for requests to finish..."
	wait
	echo "Done"
	echo
done

Tag for 0.2.20?

I notice that Azure Websites runs iisnode.dll version 0.2.20. Is it possible to build this version of iisnode?

Add support for encrypted Web.config appSettings section

Currently if a site using IISNode has an encrypted <appSettings> section in the Web.config using aspnet_regiis.exe IIS return HTTP 500.1000 stating that the IISNode module is not recognized.

Is there any way currently to use an encrypted Web.config with IISNode? If not, this should be added, it would add a great deal of value and usability to the module.

This was added as an issue 3 years ago with this issue on the original IISNode repo. Still no responses on that issue, hopefully this one gets some attention.

debugging not work in IIS 7.5

System: Win08 R2, IIS 7.5, iisnode-full-v0.2.26-x64.msi, node-v10.15.1-x64.msi

Installed "C:\Program Files\iisnode\setupsamples.bat", and every thing is fine, except debugging.
As mentioned in tjanczuk#372, IIS 7.5 not support default debuggerExtensionDll, and indeed.
So I add this in web.config: <iisnode debuggerExtensionDll="iisnode-inspector.dll" />

Visit .../node/helloworld/hello.js/debug, and I get errors:

iss01

Note: some JS files (marked green) content (marked red) is not right:

The iisnode module is unable to deploy supporting files necessary to initialize the debugger.
Please check that the identity of the IIS application pool running the node.js application has
read and write access permissions to the directory on the server where the node.js application is located.

And those JS files is random with each browser fresh:

iss02

I found that each browser fresh results in full debug files recreation in C:\Program Files\iisnode\www\helloworld\hello.js.debug\node_modules, even though they already exists.

If I open those JS with browser individually, its content is correct.

I check those JS files in C:\Program Files\iisnode\www\helloworld\hello.js.debug\node_modules\node-inspector\front-end\, their content is correct.

I tried previous versions of iisnode (v0.2.15 ~ v0.2.26), still no luck, same issue.

Unusual: log has 22 times of this event for one browser fresh:
<Data>iisnode unpacked debugger files</Data>

Custom error messages are overwritten by IIS

Hello,

using code like this:

const app = require('express')();
app.use(function (req, res) {
    res.sendStatus(502, "engine mismatch error");
});
app.listen(port);

from node under iisnode, custom error message "engine mismatch error" is overwritten with "Bad Gateway" by IIS. The solution of the problem is in the pull request #39 , thank you @mparq !

Could be this pull request please be merged into the main stream?

Regards
yarick123

Serving static Socket.io.js on Azure NodeJS WebApp

We are having a problem serving a few of the socket.io client javascript files through node. The files are being served but have some characters added to the beginning and the end of the files which is breaking our browser. The added characters look suspiciously like Byte order marks.

When run locally on IIS it works fine. When running as an Azure web app (IIS 10.0) then the files are served with the extra characters.

A stack overflow post describes the exact same problem we are having.

Environment:
Node 10.15.2
Socket.io 2.2.0
Express 4.16.4

Interpret 'nodeProcessCommandLine' as a relative path

Hey,

We need this feature (see #55) in our implementation and currently we are solving this by manually merging this. We made this same pull request in the original repository tjankczuk/iisnode-448, but this got closed 'due to security reasons', without any real reasoning, while there seemed to be some support for the issue.

So this is our attempt to get you to reconsider on this pull request. :)

[QUESTION] How to implement iisnode in a windows container?

Hi guys, do you have some resource links about how to implement iisnode in a windows container?, I already tried to create it from a base image like microsoft/iis and then I installed iisnode, urlrewrite and set the correct permissions ... but when I create the container from that image appears me an error when Node.js try to run the line app.listen(80); in the server.js file ...

IISNode crashes if appSetting is too long

We have an appSetting in our web.config whose value is over 90,000 characters in length and it appears to be causing IISNode to crash (the exception appears to manifest itself as a heap corruption).

eg <add key="Microsoft.Portal.Framework.ParameterizedSettings" value="[SUPER LONG VALUE HERE]" />

My guess is that IISNode is crashing when trying to convert the setting to an environment variable since it looks like it allocates a max tmpSize of (32767 - envirnomentSize).

The IISNode instance is running 32bit.
Version 0.2.26

Plans for future maintenance

Hello,
I'm currently deploying a business-critical application using iisnode on IIS 10, and was wondering if there are plans for continual maintenance on this project. I'm aware that iisnode works on IIS 10, but as updates occur, we'll need to continue to support this project, and I want to verify that iisnode will continue to work.

IISNode responds with HTTP500.1013 after subsequent requests with long processing time (around > 5 seconds)

Repro Steps

Using Azure AppService with Node v8.0.0, IISNode v0.2.21
Using default settings in IISNode, Web.config. No iisnode.yml

Producer (server.js)

var http = require('http');
http.createServer(function (req, res) {
    setTimeout(() => {
        res.writeHead(200, {'Content-Type': 'text/html'});
        res.write('hi');
        res.end();
    }, 6000);
}).listen(process.env.PORT);

Consumer (tester.py)

import requests
import time

for i in range(0, 10):
    t0 = time.time()
    r = requests.get('https://***.azurewebsites.net/hi')
    t1 = time.time()
    print(str(r.status_code) + " in " + str(t1-t0) + "ms")

Output

200 in 6.27462887764ms
500 in 5.32504105568ms
200 in 6.14366197586ms
500 in 5.32526397705ms
200 in 6.14505696297ms
500 in 5.32463908195ms
200 in 6.14349889755ms
500 in 5.32335090637ms
200 in 6.34911417961ms
500 in 5.324187994ms

Choose what npm command to run

Currently, the way the web app starts is using iisnode pointing to a file:

image

What I want to be able to do instead, is to choose which npm to run. In this case, it will run node dist/api.js in my case. I want to tell iisnode to run npm start instead.
Is that possible?

CORS request not working on Azure using iisnode

I have an nodejs/expressjs Web API project setup that works perfectly fine when I test it using curl.

Here is the output for the local call:

image

However when I deploy to azure and try executing the same curl statement, it gives me the following:

image

I am sure this has to do with iisnode and iis on azure. What I don't know is how to configure the Azure WebSite to allow the OPTIONS preflight check to pass through to nodejs.

My server.js code is using the cors npm package. This code works locally when I configure nodejs and express but it seems that IIS on Azure is blocking or causing issues with my code.

How do I configure CORS requests using iisnode to make sure it is passed on to nodejs? I have tried several different options in the web.config to no avail.

Provide a mechanism for specifying settings that is not based on the filesystem

In some scenarios, settings such as logging and dev errors need to be enabled/disabled but updating the file system is not an option. For example, the app might be running in Azure WebSites as a site extension, which means the files are on the disk of the worker and are readonly. It would be ideal if the various iisnode settings could also be set via environment variables or some other mechanism that would work in this scenario.

NodeJS Process not being restarted on source changes

According to this document (from 2011 I know) IISNode should automatically detect changes in the node application and gracefully update it.

Auto-update. The iisnode module ensures that whenever the node.js application is updated (i.e. the script file has changed), the node.exe processes are recycled. Ongoing requests are allowed to gracefully finish execution using the old version of the application, while all new requests are dispatched to the new version of the app.

In my experience this is not happening.

I've had a nodejs-express with socket.io application running under IISNode and while everything works as it should, if I save changes in any of the file, IIS is not reading them and keep serving the version loaded previously.

If I manually restart the website from IIS, the changes are picked up as they should.
Node (v10.9.0) + Express (v4.16.2) + Socket.io (v2.0.4)

Is this a behaviour someone else noticed?

Unable to run a Next js app on IIS node

I'm trying to run a Next.js app in an Azure Web Service, but since I was unable to get it working (I was getting strange & unhelpful errors) I pulled it down to my machine and installed iisNode. I am now getting the same, unhelpful error message:

iisnode encountered an error when processing the request.

HRESULT: 0x2
HTTP status: 500
HTTP subStatus: 1001
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:

(node:16696) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.

That is it. There are no more logs anywhere (other than the std output which doesn't contain much), there's nothing in the Windows Event Viewer and I can't start the Node debugger (calls to '/debug' also fail with this same error).

I'm completely stumped; I've had my colleagues try this as well and at the moment this error is so reliable that I'm starting to come to the conclusion that IIS Node simply cannot run a Next.js app. Is this something that can be fixed?

iisnode based worker process crash

We have an IIS - NodeJS application and iisnode.dll is causing crashes with some fatal communication errors from WAS, around same time every day. On crash dumps, there are Parallel Exceptions on thread #3 , #4, #5, #6, the same time cause WER to kill the Proc.

3  Id: 2214.21c Suspend: 1 Teb: 00007ff6`ed335000 Unfrozen

Child-SP RetAddr Call Site
0000008747d2f390 00007ffacee2b7e4 ntdll!RtlpWaitOnCriticalSection+0xb6
0000008747d2f460 00007ffab6c87d98 ntdll!RtlpEnterCriticalSectionContended+0xa4
0000008747d2f4a0 00007ffab6c9da36 iisnode!CAsyncManager::TimerWorker+0x18
0000008747d2f4e0 00007ffab6fcb100 iisnode!CNodeHttpStoredContext::GetConnectionRetryCount+0x16
0000008747d2f530 00007ffab6fc27ba iiscore!NOTIFICATION_CONTEXT::RequestDoWork+0x2a2
0000008747d2f580 00007ffab6fc9ef6 iiscore!NOTIFICATION_CONTEXT::CallModulesInternal+0x1aa

4 Id: 2214.3118 Suspend: 1 Teb: 00007ff6ed333000 Unfrozen Child-SP RetAddr Call Site 0000008747d2f390 00007ffacee2b7e4 ntdll!RtlpWaitOnCriticalSection+0xb6 0000008747d2f460 00007ffab6c87d98 ntdll!RtlpEnterCriticalSectionContended+0xa4 0000008747d2f4a0 00007ffab6c9da36 iisnode!CAsyncManager::TimerWorker+0x18 0000008747d2f4e0 00007ffab6fcb100 iisnode!CNodeHttpStoredContext::GetConnectionRetryCount+0x16 0000008747d2f530 00007ffab6fc27ba iiscore!NOTIFICATION_CONTEXT::RequestDoWork+0x2a2 0000008747d2f580 00007ffa`b6fc9ef6 iiscore!NOTIFICATION_CONTEXT::CallModulesInternal+0x1aa
..

I have cloned the same version (0.2.21 for iisnode.dll) from Github and build to resolve the symbols , but i forced it since there was a mismatch, that’s why not very sure, if function names are correct or not.
The cause of the issue is that; Access violation when adding a data on Critical Section Debug information, is failing:

ExceptionAddress: 00007ffacee2de0e (ntdll!RtlpWaitOnCriticalSection)
ExceptionCode: c0000005 (Access violation)
ExceptionFlags: 00000000
NumberParameters: 2
Parameter[0]: 0000000000000001
Parameter[1]: 0000000000000024
Attempt to write to address 0000000000000024 --> This is the address of Critical Section objects, debugInfo section, which is indeed Null.

Meanwhile, we seem to have some App kill operations on Thread #32:

0:032> kpn6
Child-SP RetAddr Call Site
000000896da7fd88 00007ffacc071118 ntdll!ZwWaitForSingleObject+0xa
000000896da7fd90 00007ffab6c96f1b KERNELBASE!WaitForSingleObjectEx+0x94
000000896da7fe30 00007ffab6caef2d iisnode!CNodeApplicationManager::EnsureDebuggedApplicationKilled+0x14b
000000896da7fe60 00007ffacc5213d2 iisnode!__vcrt_initialize+0x11
000000896da7fe90 00007ffacee054f4 kernel32!BaseThreadInitThunk+0x22
000000896da7fec0 0000000000000000 ntdll!RtlUserThreadStart+0x34
..

Can it be a consequence of killing some node apps / broken pipe(s)?
On “0.2.26” on following repo, there are some fixes, about IIS service crash but not %100 sure if these are related.

Thanks,
Mert

Socket.IO - Node crash when Client tries to use WebSocket

Hi! :)

Sorry for the newbie question. I'm trying out the Socket.IO Chat Example with Node hosted in IISNode in Azure Cloud Service

Long polling seems fine. But, when Client tries to establish WebSocket, I see from Fiddler the following response

HRESULT: 0x6d
HTTP status: 500
HTTP subStatus: 1013
HTTP reason: Internal Server Error

And, I have reason to believe Node crashes from this, and that a new Node instance is spun up

Question1: Does anyone know what the issue might be?

Question2: When Node crashes, is there a place to get logs of why it crashed?

Note1: I did follow the example web.config where we disable WebSocket for IIS (so that Node can handle it)

Note2: There should only be one Node process (default nodeProcessCountPerApplication of 1)

I'm rather stumped, and any help would be great, thanks! :)
-Michael

Node-Inspector Errors

Can't see what I am doing wrong but for the life of me, cannot get the debugging to work. Site runs fine. Running IIS 8. Made sure my app pool account has rights to the application folder is inetpub.
Web config shown below. When I run the debugger, I get a bunch of "Unexpected identifier" syntax errors in chrome console. Files getting these error changes every time I refresh. Last error states websocket connection failed during handshake. Anyone have an ideas?

    <rule name="NodeInspector" patternSyntax="ECMAScript" stopProcessing="true">
      <match url="app.js\/debug[\/]?" />
    </rule>
    
    <rule name="StaticContent">
      <action type="Rewrite" url="public{REQUEST_URI}" />
    </rule>        
    
    <rule name="myapp" patternSyntax="Wildcard">
      <match url="*" negate="false" />
      <conditions logicalGrouping="MatchAll" trackAllCaptures="false">
        <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="True" />
      </conditions>
      <action type="Rewrite" url="app.js" />
    </rule>
    
  </rules>
</rewrite>
<caching>
    <profiles>
        <add extension=".js" policy="DisableCache" kernelCachePolicy="DisableCache" />
    </profiles>
</caching>
<!-- 'bin' directory has no special meaning in node.js and apps can be placed in it -->
<security>
  <requestFiltering>
    <hiddenSegments>
      <remove segment="bin"/>
    </hiddenSegments>
  </requestFiltering>
</security>
<httpErrors existingResponse="PassThrough" />

How to ensure iisnode respects NODE_PATH?

It is not uncommon to want to be able to have non-relative imports, for example, for configuration, etc...

In the world of running a node executable on your own (development env, any other cloud provider that isn't azure... things like that) you can simply set an env var and have it respected by the node runtime.

Imagine a project structure like so:

dist
|--foo
    |--bar
        |--baz
            app.js
|--config

in app.js with NODE_PATH=dist, I can simply require('config') and have what I need.

Within Azure App Services, it appears to ignore NODE_PATH from Application Settings, so... what am I missing to make this work, or is this simply not possible :( ?

Error loading site

I'm trying to port over an existing node site to windows and iis node -

I've installed node.js, iisnode (the "full' version or "iisnode for iis 7.x (x64) full" under installed programs).
I'm able to install and run the samples, and create new node sites - so the environment seems to be working fine.

When I try to run my ported app using iisnode, where I've created what I think should be a proper web.config file for my app, I get an error whenever I try to browse to my site:

Cannot GET /mywebsite/server.js

I can run the etw.bat file - but there's nothing, anywhere that gives me a good hint as to what's not working in my project. Any advice on where to look?

iisnode doesnt appear to allow for catching any process exit signals inside node.

I have tried everything I can think of to detect node shutdown on azure webapps (for graceful exits). I can detect shutdown on normal node on windows, but not in Azure.

Some listeners that never fire:

        process.on('SIGINT', handle);
	process.on('SIGTERM', handle);
	process.on('SIGHUP', handle);
	process.on('SIGBREAK', handle);
	process.on('exit', handle);

also the older readline method does not work either:

         let rl =require("readline")
	.createInterface({
		input: process.stdin,
		// output: process.stdout
	})
	.on("SIGINT", function () {
		console.log('rlsigint');
	})

Is it not possible to detect node shutdown at all in iisnode for the purposes of cleaning up, sending last logs to db, etc?

Route not reached - 404

Hi,

I would like to run this application (https://github.com/catamaican/gamification) with IISNode.

Steps:

  • installed IISNode
  • installed gamification and modified "config/default.json" >> "port": "PORT"
  • my web.config is bellow:
    `
` The "app.js" is just ` require(__dirname + '\\src\\index.js'); ` so that it calls the main application (it work in plain Node)

I would like to have the IISNode app run at "http://localhost/gamification" >> I've created an IIS application poiting to a folder and on that folder I've set up permissions for "IIS_IUSRS" (FULL)

NOW - for anything that I try (excep "public") I get 404.

Further testing:
is the end of "src/app.js" I've added
app._router.stack.forEach(function(r){ if (r.route && r.route.path){ console.log(r.route.path) } })
so that I could see all the routes >>
/achievements /achievements/:__feathersId /xp /xp/:__feathersId /events /events/:__feathersId /user /user/:__feathersId /leaderboard /leaderboard/:__feathersId
However, when I point to localhost/gamification/user/user123, all I get is 404 and I don't know why.

HELP, please!

Support for Nano Server

Windows Nano Server doesn't come with msiexec, so I'd have to extract the files from the MSI in another OS and follow the installation steps manually.

How easy would it be to provide non-msi releases? Perhaps a powershell script to set everything up?

DeprecationWarning: Buffer() is deprecated

"new Buffer()" constructor has been deprecated in Node.js
https://nodejs.org/docs/latest/api/buffer.html#buffer_buffer_from_buffer_alloc_and_buffer_allocunsafe

interceptor.js needs to be updated

Pull request created in June for the original iisnode repo but is still not merged

tjanczuk#636

For anyone that wants to fix there local install, it's any easy change, see the file update on the pull request
https://github.com/tjanczuk/iisnode/pull/636/files
Update this file: C:\Program Files\iisnode\interceptor.js

Express req.protocol returning "http" when it should be "https"

I have an Express 4 back-end hosted in IIS w/ IISNode installed.

I'm sending a request via the front-end, which is (statically) hosted on the same Express server as the back-end. I'm using the fetch api from Chrome to send a PUT request to the server.

The request URL is clearly HTTPS not HTTP, yet when I check req.protocol in the back-end, it shows as "http".

Is there some header I need to add to my request (or perhaps a web.config setting) to get req.protocol to correctly report whether I'm on HTTPS or HTTP?

In case it helps, here's the full header I'm seeing in the Network tab in Chrome:


General

Request URL: https://some-domain.com/sandbox/api/account/reset-password
Request Method: PUT
Status Code: 200
Remote Address: 192.168.0.251:443
Referrer Policy: no-referrer-when-downgrade


Response Headers

content-length: 2
content-type: text/plain; charset=utf-8
date: Thu, 07 Mar 2019 00:37:32 GMT
etag: W/"2-nOO9QiTIwXgNtWtBJezz8kv3SLc"
server: Microsoft-IIS/10.0
status: 200
x-powered-by: Express
x-powered-by: ASP.NET


Request Headers

:authority: some-domain.com
:method: PUT
:path: /sandbox/api/account/reset-password
:scheme: https
accept: /
accept-encoding: gzip, deflate, br
accept-language: en-US,en;q=0.9
content-length: 68
content-type: application/json
cookie: _ga=GA1.2.2070104126.1551729880; __utma=237462913.2070104126.1551729880.1551729880.1551729880.1; __utmz=237462913.1551729880.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none)
origin: https://some-domain.com
referer: https://some-domain.com/sandbox/account/reset-password
user-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/72.0.3626.121 Safari/537.36


Request Payload

{emailAddress: "[email protected]", password: "some-password"}

Random HTTP 500.1013 errors from IISnode

I'm working on the Botbuilder framework using the NODEjs SDK and i have the current setup for directline conversations

  • A nodejs web UI which is a chat interface for the bot
  • A nodejs bot logic server

Both these servers are hosted in an azure web app (windows server 2016) with an IIS-node webserver

Currently the server containing the bot logic has the below routes (using the restify framework)

   server.post('/receiveMessage', connector.listen());
    
    server.post('/beginSpecialDialog', function(req,res,next){
        var _body = req.body;
        logger("info", "server", "/beginSpecialDialog triggered", null, {"conversationId": _body._directlineAddress.conversation.id})
        if(_body._directlineAddress.secret !== config.BOT.DIRECTLINE_SECRET){
            logger("warn", "server", "directline credentials do not match", null, {"conversationId": _body._directlineAddress.conversation.id, "secretSent":_body._directlineAddress.secret, "err":err});                            
            res.send(401);
        }
        bot.beginDialog(_body._directlineAddress, _body._dialogId, _body._specialParams, function(err){
            if(err){
                logger("warn", "server", "error occured on starting main dialog from url", null, {"conversationId": _body._directlineAddress.conversation.id, "err":err});
                res.send(400, {"err": err.stack });
            }
            else{
                res.send(200);
            }
        });
    });

The /beginSpecialDialog is initiated by the webUI server whenever we need to convey the bot to start a special Dialog for the webUI browser.

However , sometimes (1 in every 10 requests or so) - this route isnt being processed by the bot server. I get a 5xx response from the bot server with the below details

</head>
<body>
<div id="content">
<div class="content-container">
<h3>HTTP Error 500.1013 - Internal Server Error</h3>
<h4>The page cannot be displayed because an internal server error has occurred.</h4>
</div>
<div class="content-container">
<fieldset><h4>Most likely causes:</h4>
<ul>    <li>IIS received the request; however, an internal error occurred during the processing of the request. The root cause of this error depends on which module handles the request and what was happening in the worker process when this error occurred.</li>    <li>IIS was not able to access the web.config file for the Web site or application. This can occur if the NTFS permissions are set incorrectly.</li>    <li>IIS was not able to process configuration for the Web site or application.</li>     <li>The authenticated user does not have permission to use this DLL.</li>       <li>The request is mapped to a managed handler but the .NET Extensibility Feature is not installed.</li> </ul>
</fieldset>
</div>
<div class="content-container">
<fieldset><h4>Things you can try:</h4>
<ul>    <li>Ensure that the NTFS permissions for the web.config file are correct and allow access to the Web server's machine account.</li>     <li>Check the event logs to see if any additional information was logged.</li>  <li>Verify the permissions for the DLL.</li>    <li>Install the .NET Extensibility feature if the request is mapped to a managed handler.</li>  <li>Create a tracing rule to track failed requests for this HTTP status code. For more information about creating a tracing rule for failed requests, click <a href="http://go.microsoft.com/fwlink/?LinkID=66439">here</a>. </li> </ul>
</fieldset>
</div>

<div class="content-container">
<fieldset><h4>Detailed Error Information:</h4>
<div id="details-left">
<table border="0" cellpadding="0" cellspacing="0">
<tr class="alt"><th>Module</th><td>&nbsp;&nbsp;&nbsp;iisnode</td></tr>
<tr><th>Notification</th><td>&nbsp;&nbsp;&nbsp;ExecuteRequestHandler</td></tr>
<tr class="alt"><th>Handler</th><td>&nbsp;&nbsp;&nbsp;iisnode</td></tr>
<tr><th>Error Code</th><td>&nbsp;&nbsp;&nbsp;0x0000006d</td></tr>

</table>
</div>
<div id="details-right">
<table border="0" cellpadding="0" cellspacing="0">
<tr class="alt"><th>Requested URL</th><td>&nbsp;&nbsp;&nbsp;https://test-bot-website:80/server.js</td></tr>
<tr><th>Physical Path</th><td>&nbsp;&nbsp;&nbsp;D:\home\site\wwwroot\server.js</td></tr>
<tr class="alt"><th>Logon Method</th><td>&nbsp;&nbsp;&nbsp;Anonymous</td></tr>
<tr><th>Logon User</th><td>&nbsp;&nbsp;&nbsp;Anonymous</td></tr>

</table>
<div class="clear"></div>
</div>
</fieldset>
</div>

<div class="content-container">
<fieldset><h4>More Information:</h4>
This error means that there was a problem while processing the request. The request was received by the Web server, but during processing a fatal error occurred, causing the 500 error.
<p><a href="http://go.microsoft.com/fwlink/?LinkID=62293&amp;IIS70Error=500,1013,0x0000006d,14393">View more information &raquo;</a></p>
<p>Microsoft Knowledge Base Articles:</p>


</fieldset>
</div>
</div>
</body>
</html>

heres the log from the IIS node webserver

2018-01-25 06:22:58 TEST-BOT-WEBSITE POST /beginSpecialDialog X-ARR-LOG-ID=da648f30-dda9-4103-8a48-862b65eef82d 443 - 23.102.157.162 - - - test-bot-website.azurewebsites.net 500 1013 109 298 1425 120540

Could anyone shed some light as to why this happens? heres my web.config file

<configuration>
  <system.webServer>
    <!-- Visit http://blogs.msdn.com/b/windowsazure/archive/2013/11/14/introduction-to-websockets-on-windows-azure-web-sites.aspx for more information on WebSocket support -->
    <webSocket enabled="false" />
    <handlers>
      <!-- Indicates that the server.js file is a node.js site to be handled by the iisnode module -->
      <add name="iisnode" path="server.js" verb="*" modules="iisnode"/>
    </handlers>
    <rewrite>
      <rules>

        <!-- BEGIN rule TAG FOR WWW and HTTP to HTTPS REDIRECT -->
        <rule name="First_Secure" stopProcessing="true">
            <match url=".*" />
            <conditions>
                <add input="{HTTPS}" pattern="OFF" />
            </conditions>
            <action type="Redirect" url="https://{HTTP_HOST}" />
        </rule>
        <rule name="Second_Redirect" stopProcessing="true">
            <match url=".*" />
            <conditions>
                <add input="{HTTPS}" pattern="ON" />
                <add input="{HTTP_HOST}" pattern="^(www\.)(.*)$" ignoreCase="false" />
            </conditions>
            <action type="Redirect" url="https://{C:2}" />
        </rule>
        <!-- END rule TAG FOR WWW and HTTP to HTTPS REDIRECT -->

        <!-- Do not interfere with requests for node-inspector debugging -->
        <rule name="NodeInspector" patternSyntax="ECMAScript" stopProcessing="true">
          <match url="^server.js\/debug[\/]?" />
        </rule>

        <!--This redirects home page to /public/index.html-->
        <rule name="DefaultDocRewrite" stopProcessing="True">
          <match url="^$" />
          <action type="Rewrite" url="/public/index.html" />
        </rule>
        
         <!--This redirects all urls to public -->
        <rule name="StaticContentRewrite">
          <action type="Rewrite" url="public{REQUEST_URI}"/>
        </rule>
         <!--This catches if the file exists under public directory and stops processing, so that iis will serve static files -->
        <rule name="StaticContent" stopProcessing="True">
           <conditions logicalGrouping="MatchAll">
            <add input="{REQUEST_FILENAME}" matchType="IsFile" />
            <add input="{REQUEST_URI}" pattern="^/public/" />
           </conditions>
        </rule>

        <!-- All other URLs are mapped to the node.js site entry point -->
        <rule name="DynamicContent">
          <conditions>
            <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="True"/>
          </conditions>
          <action type="Rewrite" url="server.js"/>
        </rule>
      </rules>
    </rewrite>
    
    <!-- 'bin' directory has no special meaning in node.js and apps can be placed in it -->
    <security>
      <requestFiltering>
        <hiddenSegments>
          <remove segment="bin"/>
        </hiddenSegments>
      </requestFiltering>
    </security>

    <!-- Make sure error responses are left untouched -->
    <httpErrors existingResponse="PassThrough" />

    <!--
      You can control how Node is hosted within IIS using the following options:
        * watchedFiles: semi-colon separated list of files that will be watched for changes to restart the server
        * node_env: will be propagated to node as NODE_ENV environment variable
        * debuggingEnabled - controls whether the built-in debugger is enabled

      See https://github.com/tjanczuk/iisnode/blob/master/src/samples/configuration/web.config for a full list of options
    -->
    <!-- Runs node processes on each core you have in the machine -->
    <iisnode watchedFiles="web.config" nodeProcessCountPerApplication="0"/> 
  </system.webServer>
</configuration>

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.