Interaction with version control (VCS) servers is one of the resource-heavy parts of TeamCity. Until TeamCity 8.0, VCS operations could only be performed by TeamCity server itself. In version 8.0, we introduced an option to execute VCS operations in a separate VCS worker service, which can run on a separate machine (or even use several VCS workers on multiple machines). For example, you can route all Git VCS traffic through one VCS worker and all Subversion traffic through another. Furthermore, you can run the TeamCity server on Linux and still be able to use TFS by running a VCS worker on a Windows machine. With large installations, VCS worker(s) installed on separate machines should noticeably decrease TeamCity server load.
By default, VCS workers are disabled and TeamCity behaves as usual, i.e. performs all VCS operations from the main server process.
VCS worker is now provided with embedded support of Team Foundation Server, Perforce, Subversion, Git, and Mercurial. We are working on expanding the list of plugins and will publish instructions on how to convert a given TeamCity VCS plugin to work in a VCS worker.
Installation of a VCS worker
Administration | VCS workerpage on the TeamCity server and download
vcs-worker.zipon the target machine
- open port 9888 in firewall
JAVA_HOMEenvironment variable to point at the installed Java JVM 1.6+
- start vcs-worker with
- make sure you can open the VCS worker URL from the TeamCity server using ping or a web browser (e.g.
<TeamCity data directory>/config/vcs-worker.properties.dist
worker.1.urlline (remove #) and specify the worker URL, e.g.
- TeamCity server restart is not required. You should be able to see the debugging information about a connected worker via
Advanced configuration of VCS worker
<vcs-worker>/conf/vcs-worker.properties.distfor more options (you can change the port, some paths, HTTP context path)
- restart vcs-worker to apply the changes
Running several VCS workers
- install another VCS worker on another machine
<TeamCity data directory>/config/vcs-worker.propertiesand add
- if needed, use
worker.2.vcsTypessettings to assign different VCS types to different workers
- save the file, no restart is required
All connected workers are listed under VCS Worker tab in the "Administration" section (