Short Answer
Infinite loading occurs when IIS cannot find dnx.exe. That happens when the publish fails to include runtimes in its output.
Solution
Use the --runtime
flag when publishing.
cd Project01
dnvm use 1.0.0-rc1-final -runtime clr <------ Set the active runtime.
dnu build
dnu publish --runtime active <------ Use the runtime flag.
The runtime flag provides the name or full path of the runtime folder to include, or active
for the current runtime on the PATH.
If that still doesn't include the runtimes
directory in the publish output, then upgrade to the most recent release of dnu
, because there is a bug in older versions.
Explanation
Infinite loading occurs when IIS cannot find dnx.exe
. That happens when the publish fails to include runtimes in its output.
Here is how to check whether a missing dnx.exe
is causing the infinite loading problem.
- Publish your web application (e.g.
dnu publish
.)
- Navigate to the publish output directory (e.g.
binoutput
.)
- Make sure
approot
untimes....dnx.exe
is present.
Here are the key files that the publish output must contain. I've omitted some other important files to for clarity.
Project01inoutput
approot
packages
runtimes <--------------------------------This is sometimes missing.
dnx-clr-win-x64.1.0.0-rc1-final
bin
dnx.exe <---------------------IIS needs to find this.
src
global.json
web
web.cmd
logs
wwwroot <-------------------------------------IIS Physical Path
External Links
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…