Multiple Agents on physical machine, wish to run cleanup task (build) but lock out other builds on the other agents.


I have multiple physical servers with multiple TeamCity agents installed. I wish to run a build that terminates certain processes such a chrome and MSBuild but that waits until it has sole lock on the physical machine.

I’ve looked at the “Shared Resources” plugin but not sure this is the best solution.

Please can anyone help.

Thanks Rich

1 comment
Comment actions Permalink

Actually, SharedResources plugin can help you:
For each physical machine create quoted shared resource with infinite quota.
For every build can use this machine non-exclusively add a read lock.
For the build, that requires exclusive lock on the machine create a write lock.

This setup will ensure, that none of the builds will interfere with the build that has taken write lock on the machine


Please sign in to leave a comment.