I am trying to deploy an ASP.NET 5 WebApp in a Windows Server 2012 R2 that has IIS 8.5 installed.
The source code that I have here is a new ASP.NET Web Application. If I build it and run it in Visual Studio 2015, then works fine.
Now... I want to use the publish wizard to deploy it in ISS 8.5 so what I do is...
- Right click on the project name (WebApplication5)
- I created a custom profile (I named as localhost)
- I add the target location. C:\inetpub\wwwroot
- I configure the Settings
- Configuration: Release
- Target DNX Version: dnx-clr-win-x64.1.0.0.rc1-update1
- Then I publish the web app.
After that, I have the following folder structure in my C:\inetpub\wwwroot
C:\inetpub\wwwroot
- approot
- packages
- runtime
- src
- ... bunch of files
- logs
- wwwroot
- css
- images
- js
- lib
- some files including web.config
Now I edited the permissions of the C:\inetput\wwwroot to include IIS_IUSRS and IUSR (I gave them full access for now to discard permission issues)
Finally, I went to ISS manager to Default Web Site -> Right Click -> Manage Website -> Advanced Settings -> and under physical path I added C:\inetpub\wwwroot\wwwroot
I restarted the IIS Server and when I try to browser to the default site I got the following message...
HTTP Error 500.19 - Internal Server Error
The requested page cannot be accessed because the related configuration data for the page is invalid. Detailed Error Information:
Module IIS Web Core
Notification Unknown
Handler Not yet determined
Error Code 0x8007000d
Config Error
Config File \?\C:\inetpub\wwwroot\wwwroot\web.config
And finally... this is the content of the web.config file...
<configuration>
<system.webServer>
<handlers>
<add name="httpplatformhandler" path="*" verb="*" modules="httpPlatformHandler" resourceType="Unspecified" />
</handlers>
<httpPlatform processPath="..\approot\web.cmd" arguments="" stdoutLogEnabled="false" stdoutLogFile="..\logs\stdout.log" startupTimeLimit="3600"></httpPlatform>
</system.webServer>
</configuration>
What am I missing? That used to be super easy on previous versions of ASP.NET but I can't configure this properly now.
Any pointers? Thanks!