Generated *.SourceManifest doesn't include additional runCommand WebDeploy settings

妖精的绣舞 提交于 2019-12-12 02:52:21

问题


I'm trying to configure a runCommand to wait more than the default value of 1 second to finish.

This is a sample pubxml code:

  <ItemGroup>
    <MsDeploySourceManifest Include="runCommand">
      <waitInterval>60000</waitInterval>
      <path>&quot;C:\Company\install-services.cmd&quot;</path>
    </MsDeploySourceManifest>
  </ItemGroup>

When I start a deployment, it successfully creates a *.SourceManifest.xml file in the temp package directory, but it only includes the path:

  <runCommand path="&quot;C:\Company\install-services.cmd&quot;" />

Furthermore, I'm deploying the whole web site from Visual Studio.

Is there any way to get more than the path parameter added to the resulting file?


回答1:


Everything is fine except that pubxml item group requires an additional XML element. The final and working result looks like the following code:

  <ItemGroup>
    <MsDeploySourceManifest Include="runCommand">
      <waitInterval>60000</waitInterval>
      <path>&quot;C:\Company\install-services.cmd&quot;</path>
      <AdditionalProviderSettings>waitInterval</AdditionalProviderSettings>
    </MsDeploySourceManifest>
  </ItemGroup>

My markup lacked the <AdditionalProviderSettings> element. Once I've added this element, the *.SourceManifest.xml generated by Visual Studio looked like this code:

...
<runCommand path="&quot;C:\Company\install-services.cmd&quot;" waitInterval="60000" />
...


来源:https://stackoverflow.com/questions/25329952/generated-sourcemanifest-doesnt-include-additional-runcommand-webdeploy-setti

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