Skip to content

Instantly share code, notes, and snippets.

@wizardnet972
Last active October 3, 2018 16:39
Show Gist options
  • Select an option

  • Save wizardnet972/4a80a1281eded02d27dbe3b53eecd472 to your computer and use it in GitHub Desktop.

Select an option

Save wizardnet972/4a80a1281eded02d27dbe3b53eecd472 to your computer and use it in GitHub Desktop.
iisnode-full-v0.2.21-x64 (1)
node-v10.11.0-x64
rewrite_amd64_en-US (1)
var express = require('express');
var fs = require('fs');
var app = express();
app.get('/', function (req, res) {
res.send('Express is working on IISNode!');
});
app.listen(process.env.PORT);
<configuration>
<system.webServer>
<iisnode nodeProcessCommandLine="C:\Program Files\nodejs\node.exe" devErrorsEnabled="true"
loggingEnabled="true"
logDirectory="iisnode" />
<!-- indicates that the server.js file is a node.js application
to be handled by the iisnode module -->
<handlers>
<add name="iisnode" path="server.js" verb="*" modules="iisnode" />
</handlers>
<rewrite>
<rules>
<rule name="myapp">
<match url="/*" />
<action type="Rewrite" url="server.js" />
</rule>
</rules>
</rewrite>
</system.webServer>
</configuration>
icacls.exe C:\inetpub\sites\Uploader /grant IIS_IUSRS:(OI)(CI)F
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment