Learning TeamCity. Following instructions from https://confluence.jetbrains.com/pages/viewpage.action?pageId=54334902 have wrote such command:
"C:\Program Files\IIS\Microsoft Web Deploy V3\msdeploy.exe"
-source:package="C:\ProgramData\JetBrains\TeamCity\artifacts\webdeploy\Development\<target environment>\TestWebApplication.zip"
-dest:auto,
computerName="https://<windows azure web site web publish URL>:443/msdeploy.axd?site=<windows azure web site name>",
userName="<deployment user name>",
password="<deployment password>",
authtype="Basic",
includeAcls="False"
-verb:sync
-disableLink:AppPoolExtension
-disableLink:ContentExtension
-disableLink:CertificateExtension
as command line build step.
All the parameters have been set in parameters in current build config. When running build I've got such exception:
The filename, directory name, or volume label syntax is incorrect.
The filename, directory name, or volume label syntax is incorrect.
'computerName' is not recognized as an internal or external command,
operable program or batch file.
'userName' is not recognized as an internal or external command,
operable program or batch file.
'password' is not recognized as an internal or external command,
operable program or batch file.
'authtype' is not recognized as an internal or external command,
operable program or batch file.
'includeAcls' is not recognized as an internal or external command,
operable program or batch file.
The filename, directory name, or volume label syntax is incorrect.
The filename, directory name, or volume label syntax is incorrect.
Process exited with code 1
Step Command Line failed
What am I doing wrong?
A command line should be indeed one line command:
"C:\Program Files\IIS\Microsoft Web Deploy V3\msdeploy.exe" -source:package="C:\ProgramData\JetBrains\TeamCity\artifacts\webdeploy\Development\<target environment>\TestWebApplication.zip" -dest:auto, computerName="https://<windows azure web site web publish URL>:443/msdeploy.axd?site=<windows azure web site name>", userName="<deployment user name>", password="<deployment password>", authtype="Basic", includeAcls="False" -verb:sync -disableLink:AppPoolExtension -disableLink:ContentExtension -disableLink:CertificateExtension
or, for better readability, escape CR/LF
line endings using ^
caret as follows:
"C:\Program Files\IIS\Microsoft Web Deploy V3\msdeploy.exe" ^
-source:package='artifacts\WebDeploy\<target environment>\AcmeCompany.Portal.zip' ^
-dest:auto, ^
computerName="https://<windows azure web site web publish URL>:443/msdeploy.axd?site=<windows azure web site name>", ^
userName="<deployment user name>", ^
password="<deployment password>", ^
authtype="Basic", ^
includeAcls="False" ^
-verb:sync ^
-disableLink:AppPoolExtension ^
-disableLink:ContentExtension ^
-disableLink:CertificateExtension ^
-setParamFile:"msdeploy\parameters\<target environment>\AcmeCompany.Portal.SetParameters.xml"
Honestly, I'm not sure about proper quoting -source:
argument target if used path would contain space(s):
-source:"package='artifacts\WebDeploy\real target environment\AcmeCompany.Portal.zip'"
and about using '
single quotes (apostrophes):
-source:"package=artifacts\WebDeploy\real target environment\AcmeCompany.Portal.zip"
or
-source:package="artifacts\WebDeploy\real target environment\AcmeCompany.Portal.zip"