简体   繁体   English

如何为具有多个Web应用程序的解决方案自定义“ ASP.NET CORE(完整框架)”构建定义模板,并将每个部署在Azure上

[英]How to customize “ASP.NET CORE (Full framework)” build definition template for a solution with multiple web apps and deploy each on Azure

I have a solution with 4 Asp.Net Core (full framework) web apps inside. 我有一个带有4个Asp.Net Core(完整框架)Web应用程序的解决方案。 How can you create the structure of the Artifacts Explorer shown in the image posted here by Donovan Brown if you create a new Build Definition using the VSO template "ASP.NET CORE (.NET Framework). 如果使用VSO模板“ ASP.NET CORE(.NET Framework)创建新的构建定义,那么如何创建Artifacts Explorer的结构,显示在Donovan Brown在此处发布的图像中”。

The template contains a Visual Studio Build (version 1*) task with MSBuildArguments "/p:DeployOnBuild=true /p:WebPublishMethod=Package /p:PackageAsSingleFile=true /p:SkipInvalidConfigurations=true /p:DesktopBuildPackageLocation="$(build.artifactstagingdirectory)\\WebApp.zip" /p:DeployIisAppPath="Default Web Site" " 该模板包含一个Visual Studio Build(版本1 *)任务,其中包含MSBuildArguments“ / p:DeployOnBuild = true / p:WebPublishMethod = Package / p:PackageAsSingleFile = true / p:SkipInvalidConfigurations = true / p:DesktopBuildPackageLocation =” $(build。 artifeststagingdirectory)\\ WebApp.zip“ / p:DeployIisAppPath =”默认网站“”

This creates a single WebApp.zip with all the web apps in the solution. 这将创建一个WebApp.zip,其中包含解决方案中的所有Web应用程序。

I want to have a zip file for every web app in the solution so that I can create Release definitions for each web app using the Azure deployment teamplate. 我想要解决方案中每个Web应用程序都有一个zip文件,以便可以使用Azure部署团队面板为每个Web应用程序创建发布定义。

Thank you 谢谢

You can create packages of web apps by using publish profiles with the same name. 您可以使用具有相同名称的发布配置文件来创建Web应用程序包。

  1. Right click the project > Publish >Create a publish profile (Custom) 右键单击项目>发布>创建发布配置文件(自定义)
  2. Select Web Deploy Package 选择Web部署程序包
  3. Specify relative path in Package location (eg ..\\..\\a\\Web1 ) 在程序包位置指定相对路径 (例如..\\..\\a\\Web1
  4. Other settings 其他设定
  5. After that, you can specify /p:DeployOnBuild=true /p:PublishProfile="[profile name]" in MSBuild Arguments of Visual Studio Build task. 之后,您可以在Visual Studio生成任务的MSBuild参数中指定/ p:DeployOnBuild = true / p:PublishProfile =“ [配置文件名称]”

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 使用visual studio团队服务构建包含多个Web应用程序的解决方案,并将这些Web应用程序部署到azure - using visual studio team services to build a solution containing multiple web apps and deploy these web apps to azure Web应用程序之间的Asp.Net核心数据保护不适用于Azure - Asp.Net Core DataProtection between Web Apps not working on Azure 如何将 asp.net 核心 web 应用程序部署到 azure b2c 租户? - How to deploy a asp.net core web application to azure b2c tenant? 如何在Azure上托管和部署ASP.Net Core 2.0 WebAPI? - How to Host and Deploy ASP.Net core 2.0 webapi on azure? 无法将ASP.NET 5(ASP.NET Core 1)部署到Azure - Unable to deploy ASP.NET 5 (ASP.NET Core 1) to Azure 在没有.NET Core和Visual Studio的情况下将ASP.NET App部署到Azure Web App - Deploy ASP.NET App to Azure Web App without .NET Core and Visual Studio 跨默认域(* .azurewebsites.net)上的Azure Web应用程序的ASP.NET Core共享身份Cookie - ASP.NET Core Sharing Identity Cookie across azure web apps on default domain (*.azurewebsites.net) ASP.NET-如何构建和自定义日历? - Asp.Net - how to build and customize a calendar? Azure上的Asp.Net Core Web API - Asp.Net Core Web API on Azure 有将ASP.NET Web应用程序更新部署到多个服务器的好的解决方案吗? - Any good solution to deploy ASP.NET web application updates to multiple servers?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM