Using MSDeploy/Web Deploy as Publish method in Visual Studio with multiple users
Asked Answered
J

2

8

Is it possible to use web deploy from multiple developer PC's?

When we try to do so it seems we need to re-publish everything when someone else wants to do a deploy.

Are we doing something wrong, is there a way around this, or what would be a recommended approach in our scenario?

I'm aware that deploying from a central location is a better founded solution, but unfortunately this is not an option at the moment.

Jamesy answered 20/11, 2012 at 8:1 Comment(0)
T
2

Using Visual Studio, no. The current build scripts don't have a way of providing the necessary flag to MSDeploy.

If you are using the generated cmd file from a package to perform the deployment you can append -useChecksum to your command line and it will use checksum comparisons rather than the last modified date.

Thermometer answered 23/11, 2012 at 4:47 Comment(3)
That's it, great, thanks! I'm still finding my way around the msdeploy and webdeploy ecosystem. Can you point me to any documentation where this is explained?Jamesy
OK nevermind about the question for documentation, it's right here: technet.microsoft.com/en-us/library/dd569089(v=ws.10).aspxJamesy
Just noting that using checksum can now be configured to be used within Visual Studio, as of version 2013. More info at: blogs.msdn.com/b/webdev/archive/2013/10/30/…Jamesy
I
17

You can't do it from your project, but it's simple to edit the Visual Studio MSBuild scripts to turn it on (for all web deploys). Here's how:

  1. Open C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v11.0\Web\Microsoft.Web.Publishing.targets
  2. Find the MSDeployPublish target
  3. Inside that task, find the call to the VSMSDeploy task (line 4376 or so)
  4. Add the UseChecksum="true" attribute to the VSMSDeploy task call

You can also do this for the deploy preview by following the same steps, but look for the MSDeployFilePreview target in step 2 rather than the MSDeployPublish task.

Make sure to restart VS after you make the changes to ensure they're properly picked up.

UPDATE: MS has added the ability to pass the UseChecksum flag to VS 2013. To do this, add the following property to the .pubxml file:

<MSDeployUseChecksum>true</MSDeployUseChecksum>

Further information can be found here

Ileus answered 13/12, 2012 at 15:25 Comment(0)
T
2

Using Visual Studio, no. The current build scripts don't have a way of providing the necessary flag to MSDeploy.

If you are using the generated cmd file from a package to perform the deployment you can append -useChecksum to your command line and it will use checksum comparisons rather than the last modified date.

Thermometer answered 23/11, 2012 at 4:47 Comment(3)
That's it, great, thanks! I'm still finding my way around the msdeploy and webdeploy ecosystem. Can you point me to any documentation where this is explained?Jamesy
OK nevermind about the question for documentation, it's right here: technet.microsoft.com/en-us/library/dd569089(v=ws.10).aspxJamesy
Just noting that using checksum can now be configured to be used within Visual Studio, as of version 2013. More info at: blogs.msdn.com/b/webdev/archive/2013/10/30/…Jamesy

© 2022 - 2024 — McMap. All rights reserved.