36

Is it possible, without disabling all other connected agents, to force TeamCity to build on a specific agents machine?

ROMANIA_engineer
  • 54,432
  • 29
  • 203
  • 199
El Toro Bauldo
  • 1,199
  • 3
  • 16
  • 26

3 Answers3

46

Under Build Configuration Settings go to Agent Requirements and set an Explicit Requirement for the specific agent name:

Parameter Name: system.agent.name

Condition: equals

Value: YOUR_SPECIFIC_AGENT_NAME

fiat
  • 15,501
  • 9
  • 81
  • 103
Jim Geurts
  • 20,189
  • 23
  • 95
  • 116
22

For one time run you can click on the 3 dots next to "Run" and define on what agent you want to run.
For a long term configuration you should use the Agent Requirements of the build.
You can add a system property to the agent by editing the file ...\buildAgent\conf\buildAgent.properties

system.special.property=true

Then you can define on the Agent Requirements to check the property system.special.property exists.

EDIT With the new version of Teamcity (5.0.*) you can now edit the Agent and select the configuration you want to run there.
Agents, select an agent, Compatible Configurations, choose "Run selected configurations only".

pauloya
  • 2,535
  • 3
  • 30
  • 50
1

TeamCity > Administration > Agents > Select an Agent > "Compatible Configurations" tab:

Current run configuration policy: "Run assigned configurations only"

Click "+ Assign configurations"

Zymotik
  • 6,412
  • 3
  • 39
  • 48