0

I am calling MSdeploy.exe using a command file (.cmd extension) In there I need to create a package at a specific location which I want to be configurable as it may change for server to server.

Is there any way to make the Destination location configurable in some xml file or something?

Currently My cmd file look like

set pathMSDeploy = "C:\Program Files\IIS\Microsoft Web Deploy\"
cd %pathMSDeploy%

msdeploy.exe -verb:sync -source:contentPath="C:\TEST_PROJECT\TestApplication" -dest:package="C:\Test.zip"

IF ERRORLEVEL 1 ( 
    ECHO %ERRORLEVEL%
    EXIT /B 1
)

I want to keep the package location configurable

chief7
  • 14,263
  • 14
  • 47
  • 80
Sidharth
  • 65
  • 9
  • Please provide an example msdeploy.exe call. Do you need to "create a package at a specific location" or deploy a package to a specific location? – chief7 Mar 10 '16 at 11:52
  • Hi @Chief7, I have updated the question with the code, I need to keep the package location configurable – Sidharth Mar 10 '16 at 13:02
  • What/who is executing the CMD file? – chief7 Mar 10 '16 at 13:55
  • there is another team that executes that file and they can not send the location for the destination package, at the max they can send us the flag which server location we need to target. – Sidharth Mar 11 '16 at 07:41
  • I'm sorry, I still don't understand why you would want to do this. Typically the developers build one package and that package is deployed to each environment. You could pass the destination path as an argument to the cmd file. Does that accomplish what you want? – chief7 Mar 11 '16 at 11:21
  • Thnx Chief7, The problem is the cmd file is run by a tool (Dimensions) and It can not pass the destination path as an argument. What it sends us is flag to which server we need to move the package and the location in the server is something we need to provide. – Sidharth Mar 14 '16 at 09:58

0 Answers0