Using Visual Studio 2015 Preview CTP6.
- Create an ASP .NET 5 New App
- Check that it is working outside of IIS.
- Once complete, publish the application. In this example, I have selected the location C:\MyPublishFolder
- When publishing your application, make sure that you have:
- Disabled pre-compilation
- Selected kre-clr-win-x18.104.22.168-beta3 OR kre-clr-win-x22.214.171.124-beta3 (See image below)
- Upon a successful publish, go to C:\MyPublishFolder.You should see the folders approot and wwwroot inside.
- Now open the IIS Manager (I am assuming you have the ASP .NET 4.5 feature enabled) with IIS 8.5
- Create a new website.
- Select the wwwrooot folder as the website’s physical path. In this example, it is C:\MyPublishFolder\wwwroot.
- Now check the website it is working
If the precompile option is ticked in the Publish Web Settings window pictured above, then you must
- Go to the wwwroot folder of your published web application. It is C:\MyPublishFolder\wwwroot
- Locate web.config
- Inside the folder of your published application, there is a packages folder inside of the approot folder which is contain a folder named after your application, with a folder for the version underneath. Inside that folder should be a folder named root. In web.config, set the value for the key kre-app-base to the root folder. For reference, see the line of code below. In this example, the application name is TestApplication.
- <add key=”kre-app-base” value=”..\approot\packages\ TestApplication \1.0.0\root” /> (See image below)