Archive

Archive for the ‘Team Foundation Server 2010’ Category

Changing URL of Team Foundation Server 2010 Projects

April 11, 2011 Leave a comment

If you want to change the URL of your projects in Team Foundation Server, sometimes it’s as straightforward as changing one URL in a dialog box.  However, good luck with that.  Probably there will be network, software configuration and work-flow after effects you need to deal with, and I thought I’d put them all in one place to make it easier for others trying to change their project URL’s.

Here is a summary of what you may have to do, and these steps are covered in this post:

  1. Change default URL in TFS administrative control panel
  2. Add new registry entry to allow default machine name to be different from URL
  3. Change TFS web config file to include your new URL
  4. Add new project location URL in Visual Studio
  5. Unbind solution from source control that points to old URL
  6. Bind solution to source control that points to new URL

This first blog post is helpful in that the author will also deal with what has to happen if  TFS is linked to SharePoint.  If simply changing the name does’t work completely further on down in interactive posts, there is a reference to changing your registry.  You’ll need to add a DWORD to HKLM\System\CurrentControlSet\Control\Lsa and call it DisableLoopbackCheck as you can see in the screen shot below.

For me, this was only part of the solution.  The other was that I had to edit the web.config file of TFS to allow me to use the new url.  Here is the link to that post.

So, after changing the URL in the TFS control panel, changing the registry and reconfiguring the TFS web site web.config file I was able to access TFS from my new URL both inside and outside of my network.

One additional issue remains.  That is in Visual Studio, your project is bound to the old location and now you’ll not only have to bind your project to your new location, but you’ll have to remove all source code bindings from the old location and change them to the new location.

To add a new TFS location, go to Connect to Team Project and then click on the Servers… button.  Then Click on add, and enter in the name of your new URL as shown below.  The old name was MMANT4, and the new name is tfs.maltercorp.com:

Connect to new TFS

To remove source control bindings from the old URL, you access that through File/Source Control.  The menu items will be different given what Visual Studio detects.  I opened my project and because it had source control bindings pointing to a different location, I got a dialog box that told me it was going to open in disconnected mode.

When you do that and then open Source Control through the File menu, you’ll see choices to unbind which I did.  Then I went back in to File/Source Control and clicked on bind to source control.  I clicked through the error messages using the ignore button.  All history is retained.

I did not test this in a multi-participant team environment, so I don’t know what will happen if you have other developers.  I suspect that they will have to unbind and bind back to source control as well as bind to a new TFS server location.  I’m sure if there are a number of developers, this will require some coordination on your part.

If I had TFS to set up all over again, I would look into what it would take to create it with a URL that is useful to outside users.

None of this was hard to do, but there was a lot of stuff in many different places, and I thought putting it all together on one place would be useful.

Follow

Get every new post delivered to your Inbox.

Join 196 other followers

%d bloggers like this: