Azure网站连续部署总是选择错误的项目 [英] Azure Website Continuous Deployment always picks up the wrong project

查看:287
本文介绍了Azure网站连续部署总是选择错误的项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在我的TFS在线有以下文件夹结构:





文件夹名称也与解决方案中的项目名称相匹配。



图例:




  • 绿点:web api 2.0项目

  • li>
  • blue dot:控制台应用程序已作为web项目添加到web项目

  • 灰色点:控制台应用程序仅用于测试



用于构建定义的工作文件夹:



构建定义是通过将Azure连接到TFS在线自动创建的,我只更改了文件夹,所以不是Team Project根文件夹,它指向此分支的文件夹,包含解决方案文件和第一张图片中的文件夹。



(这指向包含解决方案文件的文件夹,

问题:
当我运行一个构建,它总是选择 ExpiringRateCardsWorker 项目(即使现在 Web 项目已经重命名(目录和项目文件),以下划线开头,



部署成功,这是我在摩纳哥看到的:



img src =https://i.stack.imgur.com/E76td.pngalt =enter image description here>



如何选择

/ questions / 24947317 / two-web-project-in-my-solution-which-one-to-deploy>这。我之前尝试过的解决方案建议那里,但 / site / deployments 文件夹是空的FTP,它不包含 deploy.cmd

解决方案

我遇到类似的部署问题的MVC应用程序使用CD在VSO中。
这个问题是与WebJob发布机制有关的。



现在我不能一次部署我的整个解决方案与WebJob,但当我删除所有webjob * .json文件和 Microsoft WebJobs发布 NuGet包从我的解决方案,我设法部署我的MVC应用程序通常。



我想我必须单独部署应用程序的这一部分,现在。


I have the following folder structure in my TFS online:

The folder names also match the project names in the solution.

Legend:

  • green dot: web api 2.0 project
  • red dot: class library
  • blue dot: console app added as a webjob to the web project
  • grey dot: console app only used for testing

Working folders for build definition:

The build definition was created automatically by connecting Azure to TFS online, and I have only changed the folder, so instead of the Team Project root folder, it points to the folder of this branch, containing the solution file and the folders in the first picture.

(This points to the folder which contains the solution files as well as all the subfolders from the first image.

Problem: When I run a build, it always picks up the ExpiringRateCardsWorker project (even now the Web project has been renamed (both the directory and the project file) to start with an underscore, so it will be first alphabetically.

The deployment is successful, this is what I see in Monaco:

How can I make it pick up the web project?

Edit: Question was closed stating to be the duplicate of this. I have since tried the solution suggested there, but the /site/deployments folder is empty on the FTP, it doesn't contain the deploy.cmd, so my question is still not answered unfortunatelly.

解决方案

I'm experiencing similar problem with deployment of MVC application to Azure using CD in VSO. This problem is somehow related to WebJob Publishing mechanism.

For now I wasn't able to deploy my whole solution with WebJob in one go, but when I've deleted all webjob *.json files and Microsoft WebJobs Publish NuGet package from my solution, I've managed to deploy my MVC App normally.

I think I'll have to deploy this parts of the application separately, for now.

这篇关于Azure网站连续部署总是选择错误的项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆