How to host a asp.net core MVC app in IIS?

Alexu

I am familiar with .Net in general but new to ASP.Net Core. I just had my first "self-hosted" ASP.Net Core MVC app running (created using templet and runs under Kestrel by default) . What I would like to do now it to host it in-process with IIS. But what I am struggling with is that I couldn't seem to find a clear and detailed instruction/document about what I need to do to get it to work. I have tried various configuration changes on my own but nothing works so far. I am running .Net Core 3.1 and using VS.Net 2019 on my Windows 10 environment. If someone could point me to the right direction it would be highly appreciated.

Brando Zhang

As far as I know, if you want to host the asp.net core application on the IIS. You should make sure you have installed the right hosting bundle.

Notice: No matter you use in-process or out-of-process, you all need install the IIS hosting bundle.

More details about how to install it, you could refer to this link.

After install the link, you could check your IIS module to make sure you have installed the right asp.net core module.

enter image description here

Then you could use VS to publish the application to right folder and create the IIS web site as below:

enter image description here

enter image description here

Create IIS website:

enter image description here

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

Host asp.net core app in IIS to access from other PC's inside the network

Publish ASP.NET MVC app on IIS

How to set up IIS6 to host ASP .NET 4 MVC4 application

How to host the basic ASP.NET Core 2 WebAPI application on IIS

Asp.Net MVC 5 Host on IIS 7.5

How to navigate to an ASP.NET Core MVC controller in Blazor app?

IIS .NET Core 5.0 MVC API - Getting HTTP Error 500.30 - ASP.NET Core app failed to start

Host .net core app with iis give a database access error

How to successfully self-host a ASP.NET MVC app or OData service for a workstation app?

ASP.NET Core MVC App Settings

ASP.NET Core MVC causing a 500 error on IIS 8.5

Asp.Net core MVC application Windows Authentication in IIS

How to warmup an asp.net core app hosted in IIS (a) on website restart and (b) on redeploy?

Host Asp.Net Web API as an Application Under Asp.Net MVC application on IIS

.Net Core Host process High CPU usage in Windows 2016 IIS in Asp.Net Core 2.2 Application

how to my asp.net mvc website host on linux (cntose) server or this website code convert into asp.net core

Get Host Address in ASP.NET Core MVC

Publishing [part] of ASP.NET MVC Core application to web host

Host an ASP.NET Core MVC application in an Azure Function

How can I host ASP.NET 5 (vNext) MVC 6 project under IIS classic mode pool

How to host asp.net webapi project with the current build on IIS

How Do I Get My ASP.NET Core Application To Host Under IIS Using WebListener and Windows Authentication?

Deploying ASP.Net MVC 4 App on IIS 7

Deploy ASP.NET MVC App on IIS Express or an other WebServer?

How to host ASP.NET Core web-app inside an Apache website?

Cannot launch asp.net core web app in IIS Express

ASP.NET Core app targeting full framework — InProcess IIS?

Deploying ASP.NET Core 2.1 React App on IIS server

Publishing an Angular 6 app with Asp.Net Core 2.1.1 on IIS