Created
October 29, 2013 21:36
-
-
Save mxrss/7223076 to your computer and use it in GitHub Desktop.
msbuild and msdeploy script
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | |
<PropertyGroup> | |
<Configuration Condition="$(Configuration) == '' "></Configuration> | |
<MsDeployPath>C:\Program Files\IIS\Microsoft Web Deploy V3</MsDeployPath> | |
<DeployPackageLocation>SomePath</DeployPackageLocation> | |
<UserName>notauser</UserName> | |
<Password>NotAPassword</Password> | |
<MachineName>noteahost</MachineName> | |
<PackageLocation>SomePackage.Zip</PackageLocation> | |
</PropertyGroup> | |
<Target Name="Publish2" DependsOnTargets="Build" AfterTargets="Build" Condition="$(Configuration) == 'Release'" > | |
<MSBuild Projects ="$(MSBuildProjectFullPath)" | |
Targets="Package" | |
Properties=" | |
DeployOnBuild=true; | |
Configuration=$(Configuration); | |
MSDeployTarget='MsDeployPublish'; | |
MSDeployPublishMethod='RemoteAgent'; | |
MsDeployServiceUrl='someurl'; | |
allowUntrusted=true" | |
/> | |
<Exec WorkingDirectory="$(MsDeployPath)" Command="msdeploy.exe -verb:sync -source:package="$(MSBuildProjectDirectory)\obj\Release\Package\${PackageLocation}" -dest:auto,computerName=$(MachineName),userName=$(UserName),password=$(Password) -setParam:kind=ProviderPath,scope=iisApp,value="Default Web Site\" -skip:Directory=//Logs"/> | |
</Target> | |
</Project> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment