问题
I realize posts like this exist, I've read/re-read and am still having issues. Most are old or not directly related and so I thought I'd re-post w/a current example.
Trying to get a basic site running in IIS 8.5+ on win server 2012 R2. At this point I'm stuck at "502.3 - Bad Gateway" (error code 80070002, module httpPlatformHandler, notification executeRequestHandler, handler httpplatformhandler)
Relevant info:
- dnx 1.0.0-rc1-final clr (x64)
- IIS - installed/verified HttpPlatformHandler 1.2 is installed (v1.2.1959)
- IIS - setup a "No Managed Code" pool/site
- On the server itself I can get the site to show up if i run the "kestrel.cmd" (generated via dnu publish) directly, from the command line and navigate to the site.
- Project.json:
{
"version": "1.0.0-*",
"dependencies": {
"Microsoft.AspNet.Server.Kestrel": "1.0.0-rc1-final",
"Microsoft.AspNet.IISPlatformHandler": "1.0.0-rc1-final",
"Microsoft.AspNet.StaticFiles": "1.0.0-rc1-final"
},
"commands": {
"kestrel": "Microsoft.AspNet.Server.Kestrel"
},
"frameworks": {
"dnx451": {}
},
"publishExclude": [
"node_modules",
"bower_components",
"**.xproj",
"**.user",
"**.vspscc"
],
"exclude": [
"www",
"node_modules",
"bower_components"
],
"scripts": {
"prepublish": [
"npm install",
"bower install"
]
}
}
- Web.config generated after dnu publish:
<configuration>
<system.webServer>
<handlers>
<add name="httpplatformhandler" path="*" verb="*" modules="httpPlatformHandler" resourceType="Unspecified" />
</handlers>
<httpPlatform processPath="approot\kestrel.cmd" arguments="" stdoutLogEnabled="true" stdoutLogFile="logs\stdout.log" forwardWindowsAuthToken="false" startupTimeLimit="3600"></httpPlatform>
</system.webServer>
</configuration>
Your help is much appreciated.
回答1:
I was getting the same issue - iis 8 - bad gateway 502.3.
I went to Turn Windows Features On or Off and enabled IIS.
I cleaned and rebuild the solution and it ran like a charm.
I hope it helps you too.
来源:https://stackoverflow.com/questions/34098155/aspnet5-vnext-rc1-iis-8-bad-gateway-502-3