* Create a Web deploy package
* Add extra MSBuild parameters onto the BuildDefinition (such as /p:CreatePackageOnPublish=true /p:DeployOnBuild=true)
Then, once you run and passed the Gated Check-in (or in fact, any TFS Build), you will find all the codes be be installed in the TFS "Drop folder".
Solution 2 : Run a Batch file with the Build definition Workflow :
To do so, you have to use InvokeProcess activity with the Workflow TFS 2010 - how to execute a batch file after build
For more details, see my other post : http://memoprojects.blogspot.com/2010/12/create-custom-workflow-for-tfs-2010.html
Solution 3 : A more "industrialized way" is to use WIX to generate your MSI
First, we have to understand how it works (Ewald Hofman is MVP VS ALM) before specifically use WIX.
Then, you should understand MSBuild ; here are the basics from the MSDN : "Compile Apps Your Way With Custom Tasks For The Microsoft Build Engine"
Finally, use this VERY detailed tutorial "Automate Releases With MSBuild And Windows Installer XML" (MSDN Mag).
Note: Here is a Hello World that will launch Notepad with a new HelloWorld.txt file after the Build,
we first start to create a MSBuild project, for instance mySmallProject.csproj
in which you can find :
<Exec Command="C:\WINDOWS\notepad.exe HelloWorld.txt" />
Then the command line :
msbuild.exe mySmallProject.csproj /t:Build
will build and at the end, it will open your NotePad !
http://tfsdeployer.codeplex.com/ but this project has only 140 downloads as per today (dec 2010).