使用diff打包包装Service Fabric后,防止Visual Studio重建 [英] Prevent Visual Studio from rebuilding after packaging Service Fabric with diff packaging

查看:100
本文介绍了使用diff打包包装Service Fabric后,防止Visual Studio重建的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

升级Service Fabric应用程序时遇到很多问题.

I am having a lot of issues upgrading a Service Fabric application.

我最初的问题是我现在正在提出一种新产品,因为它特别涉及差异包装.

I am raising a new one now as this relates specifically to diff packaging.

我已经修改了包裹,以删除我不想接触的服务.

I have modified my package to remove the services I don't want to touch.

但是当我通过Visual Studio发布时,它会进行完整的构建.

But when I publish via Visual Studio, it does a full build.

如果我尝试通过右键单击单独运行PowerShell脚本,则它将不起作用:

If I try to run the PowerShell script on its own by right clicking on it, it does not work:

 Cannot validate argument on parameter 'PublishProfileFile'. The "Test-Path $_ -PathType Leaf" validation script for the argument with value 
"MYPATH\Scripts\..\PublishProfiles\Local.xml" did not return a result of True. Determine why the 
validation script failed, and then try the command again.
At MYPATH\Scripts\Deploy-FabricApplication.ps1:173 char:39

有人可以建议什么吗?

如何在PowerShell中运行该脚本而不会出现错误?我没有使用PowerShell的丰富经验,并且我绝对不想从头开始创建升级脚本!

How can I run this script in PowerShell without errors? I don't have much experience with PowerShell and I definitely don't want to have to create an upgrade script from scratch!

此刻,我正在尝试在本地5节点群集中工作.

At the moment I am trying to get this working in a local 5-node cluster.

推荐答案

好,我通过创建对命令文件的调用来解决了这个问题,该命令文件清除了不需要的包

ok I got around this by creating a called to a command file which clears out the unrequired packages

<Target Name="AfterPackage" AfterTargets="Package">
    <Exec Command="Upgrade\upgrade.cmd" />
  </Target>

现在还有另一个问题,但是我要为此创建一个新问题

There is another issue now but I am going to create a new question for that

这篇关于使用diff打包包装Service Fabric后,防止Visual Studio重建的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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