exe命令行上设置目标网站

exe命令行上设置目标网站

本文介绍了如何在MSDeploy.exe命令行上设置目标网站的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

限时删除!!

我有一个要部署到远程服务器的Web Deploy 3.5程序包.如何在MSDeploy.exe命令行上指定站点的名称?

I have a Web Deploy 3.5 package that I want to deploy to a remote server. How do I specify the name of the site on the MSDeploy.exe command line?

这是我到目前为止所拥有的:

Here's what I have so far:

C:\Program Files (x86)\IIS\Microsoft Web Deploy V3\msdeploy.exe
    -source:package='package.zip'
    -dest:auto,computerName="ServerName",includeAcls="False"
    -verb:sync
    -disableLink:AppPoolExtension
    -disableLink:ContentExtension
    -disableLink:CertificateExtension
    -setParamFile:"package.SetParameters.xml"

但是站点的名称是在package.SetParamters.xml文件中指定的,我希望在命令行上进行设置.我想在其中部署此软件包的某些位置是位于同一服务器上的不同站点,例如我们的Stage和UAT站点.

But the name of the site is specified in the package.SetParamters.xml file, and I'd prefer to set it on the command line. Some of the places I want to deploy this package are different sites located on the same server, like our Stage and UAT sites.

我研究了如何使用此处描述的iisApp和appHostConfig提供程序: http://technet.microsoft.com/en -us/library/dd569040%28v = ws.10%29.aspx

I've looked at using the iisApp and appHostConfig providers described here:http://technet.microsoft.com/en-us/library/dd569040%28v=ws.10%29.aspx

但是我在将它们与打包文件结合使用时遇到了麻烦.

But I'm having trouble using those in combination with a package file.

推荐答案

您可以使用setParam覆盖它:

msdeploy.exe
    -source:package='package.zip'
    -dest:auto,computerName="ServerName",includeAcls="False"
    -verb:sync
    -disableLink:AppPoolExtension
    -disableLink:ContentExtension
    -disableLink:CertificateExtension
    -setParamFile:"package.SetParameters.xml"
    -setParam:name="IIS Web Application Name",value="site name"

这篇关于如何在MSDeploy.exe命令行上设置目标网站的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

1403页,肝出来的..

09-06 22:00