TeamCity Symbol Server plugin

official JetBrains project License build status

Allows using TeamCity as a symbol and source server.

Features

Download

You can download the plugin and install it as an additional TeamCity plugin for TeamCity 10.0+.

Requirements

On the build agents should installed:

Reported agent configuration parameters

During initialization this plugin reports the following agent configuration parameters:

Usage

TeamCity as a symbol server should be referenced by the following URL <TEAMCITY_SERVER_URL>/app/symbols. The exact URL is available on the Administration | Integrations | Symbol Server page.

To enable symbols and sources indexing, add the Symbol Files Indexer build feature to the build configuration. After that all PDB files published as build artifacts of this configuration and all related sources will be indexed. The PDB files packed via TeamCity artifact publishing rules will be handled correctly.

For step-by-step instruction, see a related TeamCity blog post.

Authentication/Authorization

The indexed data can be accessed in both modes: public (not requiring authorization) and authorized. The plugin uses standard authentication settings provided by the TeamCity server.

The following permissions are checked:

These are the default permissions of Project Developers.

If you are using the public URL to access symbols, you need to enable the Guest user login and assign the project developer role to the Guest to the Developers group.

When logging into TeamCity as a guest user, the corresponding permissions are checked to grant anonymous access to symbols and sources. If the guest user permissions are insufficient, all enabled HTTP authentication modules are applied and the user will be asked for credentials.

The access mode can be configured globally or on a project-level. Also, different access modes can be specified for the symbols and sources.

Using in docker containers

To use symbol indexing in build agents started from docker agent images you need to build a derrived image like that:

FROM jetbrains/teamcity-agent:latest-windowsservercore

# Install Windows SDK
RUN Invoke-WebRequest https://download.microsoft.com/download/5/A/0/5A08CEF4-3EC9-494A-9578-AB687E716C12/windowssdk/winsdksetup.exe?ocid=wdgcx1803-download-installer -OutFile winsdksetup.exe; \
    Start-Process winsdksetup.exe -Wait -ArgumentList /features + /q ; \
    Remove-Item -Force winsdksetup.exe

Overriding source server paths

If the URL of your Teamcity server changes, source indexing will not work for old builds because the old PDB files will still be referencing the old Teamcity URL. To fix this, you can override the Teamcity source path using the srcsrv.ini file. In the [variables] section, set TEAMCITY_BASE_PATH to the sources path of the new Teamcity server. For example:

[variables]
TEAMCITY_BASE_PATH=https://new_teamcity.example.com/app/sources

Common Problems

Failed to find Source Server tools home directory

Please ensure that Debugging tools for Windows were installed on the build agent.

Unable to view symbols in IDE

Build

This project uses gradle as a build system. You can easily open it in IntelliJ IDEA or Eclipse.

Contributions

We appreciate all kinds of feedback, so please feel free to send a PR or file an issue in the TeamCity tracker.