30

Publishing ASP.NET Core 3.0 application as self-contained executable to Azure Ap...

 4 years ago
source link: https://www.tuicool.com/articles/I3mim2J
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

With Visual Studio 2019 we can publish ASP.NET Core 3.0 applications as self-contained executable . It’s specially useful for environments where ASP.NET Core 3.0 is not installed or where we don’t have permissions to install it. Here’s how to do it.

All the magic happens when we create publishing profile for ASP.NET Core 3.0 application in Visual Studio and click Advanced… link.

FNB3mmQ.png!web

If you have existing publishing profile then just open it and click on edit icon after Target framework.

j6ZJbeu.png!web

Notice two options in this dialog:

  • Deployment mode. It is either Framework-Dependent (target framework must be available on App Service) or Self-Contained (no need to install target framework before deployment).
  • Target runtime. This must match the platform and hardware architecture of target machine. I went with win-x86.

Select target runtime, save profile and publish your application. If everything went okay then very soon new browser instance opens with your ASP.NET Core 3.0 application running on Azure App Service.


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK