I created a Blazor Server App targetting .NET 5 on a workstation having Windows 10. I used Visual Studio 2019 Community Edition to create the basic Blazor Server Template app.
The app works fine when debugged on the development machine (Windows 10).
I have a web server running Windows Server 2019 and having IIS and .Net Framework 4.7 selected.
I installed .NET6 hosting bundle on the server
I restarted the server and hosted the app in C:/inetpub/wwwroot/
and configured IIS to use CLR version 4 Integrated pool.
When I tried to view the application from the browser I get the error:
HTTP Error 500.31 - Failed to load ASP.NET Core runtime.
I even tried to install .NET 5 runtime on the server but that did not help. the same error kept showing.
I tried to build the blazor app targeting .NET Core 3.1 but the same error kept showing.
What am I doing wrong?