다음을 통해 공유


Team Project Collection Deliver

One of the great new functionalities in Team Foundation Server 2010 is the ability to take a team project collection and connect it to an entirely different TFS system.

So, for example, if you were a consultant with your own TFS system and you built a starter project for the company Contoso, you can build the project on your own TFS instance and then deliver it in its entirety to Contoso when you are done.  Here are the steps for this process

 The attached Word document includes pictures to help you through this process.

Pre-Deliver Steps

Step 1: Make a new Team Project Collection

It can be difficult to deliver a single project if it is in a Team Project Collection (TPC) that is populated with non-delivered projects. So, for best results, if you know you are going to deliver a project, then create a new TPC for it.

Step 2: Make a new Team Project

You need a project if you are going to deliver it 

Step 3: Work on and finish your project

Deliver Steps On Original Server:

Step 4: Stop Working on the project

Once you are ready to deliver a project, you should stop working on it to avoid problems

Step 5: Detach the team project collection

You will need to detach the team project collection from the TFS server. This will store crucial information in the team project collection that allow it be hooked up to another TFS instance.

Step 6: Backup the project collection

You'll need to backup the team project collection database in SQL using the process described here: https://msdn.microsoft.com/en-us/library/ms187510.aspx

Set 7: Backup the SharePoint Site collection (only if SharePoint site collection will be delivered)

You'll need to backup the SharePoint site collection using the backup command under stsadm. This command must be run as an admin

stsadm -o backup -url <site_name> -filename <file_where_backup>

for example

stsadm -o backup -url https://contoso/sites/DefaultCollection -filename c:\default_collection.bak

More information on this command can be found here: https://technet.microsoft.com/en-us/library/cc263441.aspx Note: stsadm is usually stored in c:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\Bin (although not allways) Must be run as admin

Set 8: Backup the Reporting Services Reports (only if reports will be delivered)

Modify the script GetReportsFromServer.rss (located here) so that gMovingCollection is the name of the project collection that you are delivering. Executing this script will create a local copy of all RDL files stored in this collection.

This script is executed by running the command:

rs -i GetReportsFromServer.rss -s https://<tfsServer>/reportserver

for example

rs -i GetReportsFromServer.rss -s https://contoso/reportserver

Deliver Steps on New Server

Step 9: Restore the project collection

You'll need to restore the team Project collection database in SQL: https://msdn.microsoft.com/en-us/library/ms177429.aspx

Step 10: Restore the SharePoint site collection (only if SharePoint site collection will be delivered)

You'll need to restore the SharePoint site Collection via the following command the restore command in stsadm. This command must be run as an admin

stsadm -o restore -url <site_name> -filename <file_where_backup>

for example

stsadm -o restore -url https://contoso/sites/DefaultCollection -filename c:\default_collection.bak

More information on this command can be found here: https://technet.microsoft.com/en-us/library/cc262087.aspx. Note: stsadm is usually stored in c:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\Bin (although not allways) Must be run as admin

Step 11: Restore the Reporting Services Reports (only if you are delivering reports)

Modify the script PushReportsToServer.rss (located here) so that gMovingCollection is the name of the project collection that you are delivering. Executing this script will push all RDL files to the server.

This script is executed by running the command (in the parent folder of the output of Step 8 to the Reporting Server on the new system).

rs -i PushReportsToServer.rss -s https://<tfsServer>/reportserver

for example if Step 8 was in the folder C:\TFS_DefaultColleciton, then while in the C:\ directory execute:

rs -i PushReportsToServer.rss -s https://contoso/reportserver

Step 12: Attach the project collection

In the admin console, attach the the newly restored database

Step 13: Edit the Default Site location for the SharePoint site (only if SharePoint site collection will be delivered)

In the admin console, change the default site location for SharePoint.

Step 14: Change the SharePoint Web application and repair connection (only if SharePoint site collection will be delivered)

When you attach the project collection, the old SharePoint web application will be added to the system. You need to change this URL to match the location of the new SharePoint connection, and then Repair this connection so that each of the projects in your delivered project collection will connect to the correct site.

Note: This step will give you two SharePoint Web Applications that have the same URL. If you want to consolidate these two SharePoint Web Applications, then you will need to manually change the SharePoint Web Application for each project. Directions for this are given in "Alternative Steps 14 and 15" below. The only problem with having two SharePoint web applications with the same URL is that if you ever want to change your SharePoint web application URL, then you will have additional Web Applications to adjust.

Step 16. You're done!

One note, if you've migrated Reporting Services reports, then this may take 2-3 hrs to populate.

Alterative Step 14: For each project in the new collection, Change the portal settings to point to the new SharePoint server (only if SharePoint site collection will be delivered)

Step 14 a. Right-Click on each project

Step 14 b. Choose Team Project Settings->Portal Settings

Step 14 c. Under the Process Portal tab check Configure URL and choose the new web application from the drop down

Step 14 d. Under the Process Portal tab check Configure URL and choose the new web application from the drop down. Click Refresh and choose Process Guidance

Alternative Step 15 Clean up the SharePoint web applications on the new server.

Step 15 a. In the Administration Console under the SharePoint Web Application tab, click on the old SharePoint application (if it exists) and click Change. In the pop-up dialog, go to Dependents and check to make sure that there are no entries present. If projects exist,  follow step 13 for those projects

Step 15 b. In the Administration Console under the SharePoint Web Application tab, delete the old server (if it exists). If you get the popup elow and you finished step 15 a. then click Yes

               

Team Project Collection Deliver.docx

Comments

  • Anonymous
    August 29, 2010
    Thanks for the great post. Im currently in the process of moving the Team Project Collection, however it is moving between two untrusted domains.Is there a way of remapping the credentials for the active and historic work items?For exampleJoe Blogs(Domain: X) -------> Joe Blogs (Domain: Y)