Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
591 views
in Technique[技术] by (71.8m points)

tfs - Connect TeamCity to Visual Studio Online

I'm trying to migrate from on-premises TFS to Visual Studio Online. We have quite elaborate TeamCity build process that we don't want to migrate away from, so having TeamCity working with VSO would be ideal.

I've created alternative user credentials (as per this article) and using these credentials in TeamCity. But when I create new VCS in TeamCity, I get connection error:

TF30063: You are not authorized to access https://myproject.visualstudio.com/DefaultCollection/MyProject

I've tried my actual credentials (not alternative ones) but nothing changed - same error.

Also I've tried using alternative credentials with tf command line tool and could not enter alternative credentials - a window popped up, asking me for my LiveId.

Any idea how to fix this?

p.s. this is how TeamCity configuration look like:

enter image description here

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

To connect to Visual Studio Online you indeed need to enable alternate credentials on the account you'll use for Team City. Ensure that at least Team Explorer 2012 and update 4 is installed on the Team City server, install the whole Visual Studio 2012 incl Update 4. Team City requires at least update 2, but Microsoft only supports Visual Studio 2012 RTM and the latest update (which is update 4).

Then in the connection screen use the following information: enter image description here

Repository URL: https://myaccount.visualstudio.com/DefaultCollection

Username: ##LIVEID##[email protected] // Your visual Studio Online User Name, must match your LiveId.

Password: ********* // The password you setup for the alternate credentials.

You can also use the VSO Service Account credentials instead of using Alternate Credentials.

Then in your VCS Root configuration map your TFVC root in the following way:

Root: $/MyProject/Path/To/Branch/Root

Check out this post on the Jetbrains Confluence site for more details.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

2.1m questions

2.1m answers

60 comments

57.0k users

...