Posts

Showing posts with the label TFS 2012

Completely remove an application tier from TFS 2012

If you ever wondered if it is possible to completely remove an application tier from the TFS Administration Console , here is an answer for you. Yes, but it is tricky and may result in a broken TFS installation. It involves messing with the catalog in the TFS_Configuration database. As a disclaimer, this method is absolutely not supported. Not by me, not by my company, not by Microsoft. Use at your own risks. So if you decide to reproduce the steps I am going to describe, please BACK UP your TFS installation (especially the Tfs_Configuration database). Now, a little bit of context before starting, TFS uses a set of tables known as the catalog to keep track of the different pieces of your installation. It contains a lot of things including the databases, the servers, the web applications, etc. Whenever you had a new piece to the installation (app tier, reporting tier, etc.) it goes into the catalog. Our problem is that for the moment there is no way to tell when you completely ...

Error when running the TFS Best Practices Analyzer with an account containing a dollar ($) sign

I recently tried to run the TFS BPA using an account containing a dollar ($) sign. It was something like "user$name". I ended up with a rather strange error message looking like the following: Cannot validate the URL provided The scan was generated using the corrected URL "%TFSServerURLValidated%". A quick look at the "Other reports" section of the scan results, I found that the tool was trying to find files in the following directory: c:\Users\ user \AppData\Roaming\Microsoft\TfsBpa\[...] The important part is highlighted. It seems that some of the PowerShell scripts are analyzing the account name as the literal user followed by a variable named $name , instead of interpreting the whole account name as a literal. As I didn't want to go through the various PS scripts in the BPA installation directory, I decided to take the lazy approach. I created a symbolic link C:\Users\user pointing to C:\Users\user$name\ using the following c...

Entity Framework and TFS Build

I recently had an issue when trying to configure automatic deployments in TFS. I was building a MS Deploy package with one build definition and deploying it with another. The application was based on ASP.NET MVC with Entity Framework as a ORM When I tried to open the application on the target server, I got an error "Unable to load the specified metadata resource". The entity data model was configured to store the model files as resources into the assembly. The error was caused by the fact that the build process was no longer executing the packaging step. Usually Visual Studio does it automatically for you but MSBuild is not so kind. You have to manually tell it to execute the EntityDeploy step. I added an instruction in the project file (containing the data model) to execute the packaging step. < Target Name = " AfterBuild " > < EntityDeploy Sources = " Models\DataModel.edmx " outputPath = " . " > </ EntityDeploy ...