VS2010, MSDeploy and parameter declaration

I am trying to deploy an ASP.NET MVC 2 application using MsDeploy. I am using VS2010 to create a package as a ZIP. Inside this zip file is a file parameters.xmlthat declares parameters that I can set.

I want to be able to set more parameters using an automatically generated file deploy.cmdas follows:

MySite.deploy.cmd 
    "-setParam:name='IIS Web Application Name',value=MySite" 
    "-setParam:name=IisVirtualDirectoryPhysicalPath,value=C:\inetpub\MySite" 
    "-setParam:name=httpBinding,value=*:80:www.mysite.dk"

This works fine except httpBinding param. This is because this parameter is not declared inside the file parameters.xmlthat is added to the ZIP container.

I can go and add this parameter declaration manually, but is there no way to do this from the command line and declare the parameters that I have in another XML file?

+3
source share
2 answers

Are you saying that the value parameter was not declared when creating the package? If so, I think you will have to add it. Either manually, or you can use the -setParam switch and synchronize the package with yourself. If you use -setParam with a name that was not declared as a parameter to start, I'm sure the value is simply ignored.

+2
source

I just look at it, but this section of MSDN compliance declareParamwith setParamthe path?

I am using MsDeploy to update my zip deployment, following the idea in this fooobar.com/questions/271360 / ... post

,

+1

Source: https://habr.com/ru/post/1743342/


All Articles