Allows using TeamCity as a symbol and source server.
You can download the plugin and install it as an additional TeamCity plugin for TeamCity 10.0+.
On the build agents should installed:
During initialization this plugin reports the following agent configuration parameters:
WinDbg_Path
- is a path to Debugging tools for Windows.
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.
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:
View build runtime parameters and data
- while accessing symbols,View VCS file content
- while accessing sources.
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.
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
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
Please ensure that Debugging tools for Windows were installed on the build agent.
- Ensure that required PDB file was indexed during the build by navigating to the hidden TeamCity build artifacts and inspect the xml files under
./teamcity/symbols/
directory. In the xml filesign
attribute contains file signature andfile
atttribute contains file name. - Navigate in your browser to the page
http://%teamcity%/app/symbols/%pdbFileName%/%fileSignature%/%pdbFileName%
and check that pdb file was downloaded. - Ensure that IDE use correct credentials to access TeamCity server. Normally VS uses Windows Credentials Manager to get and store credentials. Failed authentication attemps are logged in the
teamcity-auth.log
server log file.
This project uses gradle as a build system. You can easily open it in IntelliJ IDEA or Eclipse.
We appreciate all kinds of feedback, so please feel free to send a PR or file an issue in the TeamCity tracker.