ASP.NET 5 (vNext) Deployment via TFS 2015

浪尽此生 提交于 2019-12-04 05:37:20

Here is what we ended up doing:

  1. Powershell script "prebuild.ps1" as per the previous answer and Microsoft deployment guidelines: https://msdn.microsoft.com/en-us/Library/vs/alm/Build/azure/deploy-aspnet5

  2. Vanilla MSBuild build. no switches or special settings.

  3. Powershell script to execute xUnit test runner. We used guidance from this post at http://fluentbytes.com/running-xunit-test-with-asp-net-dnx-and-tfs-2015-build/

  4. Powershell script to run "dnu publish". This creates a directory of the entire web application's structure.

  5. "Windows File Copy" task to deploy the directory structure created in #4 to all of the target machines in the test environment.

To build and deploy ASP.NET 5 via TFS2015 vNext build system, you need to:

1). Create a PowerShell script (named Prebuild.ps1, for example) to install DNX. Details of the PowerShell script can be found: https://msdn.microsoft.com/en-us/Library/vs/alm/Build/azure/deploy-aspnet5 . Add the script file into TFS version control.

2). Add the PowerShell script build step into build definition. Run the Prebuild.ps1 script in this step:

3). In the MSBuild step, specify the project needs to be built, and add the following /p:DeployOnBuild=True /p:DeployTarget=MSDeployPublish /p:CreatePackageOnPublish=True /p:MSDeployPublishMethod=InProc /p:MsDeployServiceUrl=localhost /p:DeployIisAppPath="Default Web Site/TFSTest1" /p:VisualStudioVersion=14.0 to publish the project to IIS.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!