The Windows IIS service provider configures an ASP. NET core server in a bad environment and deploys

Source: Internet
Author: User
Tags net core windows server hosting server hosting microsoft download center

Translated from Https://docs.microsoft.com/en-us/aspnet/core/publishing/iis

Supported Operating systems:

Windows 7 or update

Windows Server R2 or update

IIS Configuration

Enable Web server and configure related options

Windows Desktop Edition system

Windows Server Edition operating system

Install the. NET core Windows Server hosting Toolkit

1. Install the. NET Core Windows Server Hosting bundle:https://aka.ms/dotnetcore.2.0.0-windowshosting

If the server is not connected to the Internet, you should download and install the Microsoft Visual C + + redistributable https://www.microsoft.com/download/before installing the hosting bundle details.aspx?id=53840

2. Restart the system or perform

>net Stop was/y

>net start w3svc

Install Web Deploy when publishing with VisualStudio

If you want to deploy your app with Web deploy within VS, install the latest version of Web deploy on the host system.

To install Web Deploy, you can use the Web Platform Installer (WEBPI) https://www.microsoft.com/web/downloads/platform.aspx

or download directly from Microsoft Download Center (HTTPS://WWW.MICROSOFT.COM/SEARCH/RESULT.ASPX?Q=WEBDEPLOY&FORM=DLC) (note link not available)

Application Configuration

1. Enable Iisintegration component

Contains the dependencies Microsoft.AspNetCore.Server.IISIntegration

Add code to the Program.cs

var New Webhostbuilder ()    . Usekestrel ()    . Usecontentroot (Directory.GetCurrentDirectory ())    . Useiisintegration ()    . Usestartup<Startup>()    . Build ();

2. Configure Iisoptions

3. Web. config

Create an IIS Web site

(Note: This management interface differs greatly from the IIS management interface of Windows7, where this configuration fails and does not go down)

The Windows IIS service provider configures an ASP. NET core server in a bad environment and deploys

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.