Day: November 30, 2017
After DryRun migration on VSTS, you have to ensure that your builds run correctly, so each build server have specific capabilities, so it can be hard to construct your build agent on Azure, if you don’t have infra as code (Template ARM, etc.), or try with hosted agent.
In order to validate the migration easily of your build layer, the practice is to define connection between your VSTS platform and your premise build agent.
Before to use hosted agent build. For information below description of each agent available on VSTS.
• Hosted VS2017 if your team uses Visual Studio 2017.
• Hosted Linux if your team uses development tools on Ubuntu.
• Hosted macOS Preview if your team uses development tools on macOS.
• Hosted if your team uses Visual Studio 2013 or Visual Studio 2015.
I suggest you to follow theses steps :
1.Firstly go to your DryRun build board https://test-dryrun.visualstudio.com/_admin/_AgentPool
2.Download agent for Windows, this action permit you to download file agent vsts-agent-win7-x64-2.124.0.zip
3. Connect to your premise server (Not azure server for this use case), create VSTS directory under your C:\, copy paste your agent file and unzip your file into this last.
4. Add proxy file into this directory.
5. Add following environment variables with good values :
6. Unzip your agent file, below result
7. Run your powershell ISE as administrator.
8. Go to your specific directory, for our case it’s test, contains all agent of test VSTS platform
cd C:/vsts/test PS C:\vsts\test> .\config.cmd
9. Provide following answer for each question.
Q1. Enter server URL ? Enter the address of your dryrun https://test-dryrun.visualstudio.com
Q2. Enter authentication type (press enter for PAT) ? Press Enter button
Q3. Enter personal access token ? Follow steps below in order to generate token
For this need, go to security section
Click on security section
Click on Add button in order to add new token with full access.
Copy paste the token into POWERSHELL ISE command prompt
After that premise server try to connect to your vsts, in order create and configure agent.
Q4. Enter agent pool (press enter for default) ? Define default as value
Q5. Enter agent name (press enter for YourServer-1) ? Define YourServer-1 as value
Q6. Enter work folder (press enter for _work)? Define _work as result
Q7. Enter run agent as service? (Y/N) (press enter for N) ? Enter Y for response
Q8. Enter User account to use for the service (press enter for NT AUTHORITY\NETWORK SERVICE)? Press Enter for this question
Below list of answers for each question
After that we can go to pool agent in order to ensure that our agent is good configured.