Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

TFS 2010 build config transform problem

I'm facing quite a problem while setting up automated TFS Builds. Basically I created new configuration called Tests, added transform config, defined different connection strings for the Database. Then defined TFS build, building whole solution with MSBuild arguments /p:DeployOnBuild=True /p:Configuration=Tests. The problem is that in the drop location (Build_PublishedWebsites\Project) I get web.config, web.debug.config, web.release.config and web.tests.config, however I would expect just one transformed web.config.

I already checked PDC presentation Web Deployment Painkillers: Microsoft Visual Studio 2010 & MS Deploy but didn't help.

Thanks for any answer.

like image 546
Zdenek Avatar asked Apr 22 '10 08:04

Zdenek


1 Answers

Web.config transforms are part of the new Web Publishing Pipeline (WPP) in Visual Studio 2010.

During the build process the "CopyWebApplication" target is executed to copy the website to the _Websites folder on the build output directory. Due to backwards compatibility reasons, MSBuild uses the "old" (VS2008) copy behavior by default and not the new WPP system.

To opt-in to using WPP, set the following MSBuild properties:

/p:UseWPP_CopyWebApplication=True
/p:PipelineDependsOnBuild=False
like image 147
ShadowChaser Avatar answered Nov 17 '22 10:11

ShadowChaser