Use IISNode to install Node.JS in IIS.
* Ensure Url-Rewrite extension to IIS is installed: http://www.iis.net/downloads/microsoft/url-rewrite
I found the install rather rough. Not exactly sure why it started working …
THe current IISNode no longer does the mistake that it used to – namely that the the 64bit installer would look for node.js in the 64 bit path. It's no longer necessary, but know that the fix for that was to copy the whole c:\Program Files\NodeJS folder to the c:\Program Files (x64)\NodeJS folder. Then the installer would work.
The first part of the work around (discussed in this thread is to copy the Node.js files to the target dir to fool the installer)
Then have to read here regarding setting nodeProcessCommandLine to point to real direction.
Proceed with setting up samples, from the command prompt (in admin mode) call %programfiles%\iisnode\setupsamples.bat
Check that the website was created:
then go check that http://localhost/node exists
The first time I navigated to the samples website, from the server itself, I got:
Ah. Yes. Newly created sample app in an site I usually shut down. Simple enough to fix:
Navigating to the fist sample I got:
but then I got:
The error message simply leads to understanding that the web.config of the application has a web.config section to play with that gives a means to configure the IIS Module to know where to find node.js
<configuration>
<system.webServer>
<handlers>
<add name="iisnode" path="hello.js" verb="*" modules="iisnode" />
</handlers>
<iisnode
...
nodeProcessCommandLine=""%programfiles%\nodejs\node.exe""
interceptor=""%programfiles%\iisnode\interceptor.js""
...
/>
</system.webServer>
</configuration>
But…unfortunately for me, it's right. It's pointing to:
* Good early stuff: http://weblogs.asp.net/jgalloway/archive/2011/10/26/using-node-js-in-an-asp-net-mvc-application-with-iisnode.aspx * http://www.hanselman.com/blog/InstallingAndRunningNodejsApplicationsWithinIISOnWindowsAreYouMad.aspx