TeamCity On-Premises 2020.2 Help

Build Configuration

A build configuration is a collection of settings used to start a build and group the sequence of the builds in the UI. Examples of build configurations are distribution, integration tests, prepare release distribution, "nightly" build.

A build configuration belongs to a project and contains builds. You can explore details of a build configuration on its home page and modify its settings on the editing page.

It is recommended to have a separate build configuration for each sequence of builds (that is performing a specified task in a dedicated environment). This allows for proper features functioning, like detection of new problems/failed tests, first failed in/fixed in tests status, automatically removed investigations, and so on.

To tackle an increased number of build configurations you can use build configuration templates and project-level parameters.

This video tutorial illustrates how to work with a build configuration in TeamCity and gives a few extra tips:

Build Configuration Settings

Build configuration settings include:

Build Configuration Types

The following build configuration types exist in TeamCity:

  • regular build configuration, defining actions and rules to apply to the source code; all the settings above are applicable

  • deployment build configuration, which deploys artifacts of other builds to some environment

  • composite build configuration, which aggregates results from several other builds combined by snapshot dependencies and presents them in a single place

Build Configuration State

A build configuration is characterized by its state visible in the UI which can be paused or active. By default, when created all configurations are active and can be paused manually as described below or automatically if the project is archived.

If a build configuration is paused, its automatic build triggers are disabled until the configuration is activated. Still, you can start a build of a paused configuration manually or automatically as a part of a Build Chain. Besides, information on paused build configurations is not displayed on the Changes page.

It is possible to manually pause all or selected build configurations for a project.

Pausing / Activating a single build configuration

On the Build Configuration Settings or Home page:

  • Open the Actions menu, click Pause, and enter your comment in the Pause dialog (optional).
    To remove the builds of the paused build configuration from the build queue, check the Cancel already queued builds box. Click Pause to confirm.

  • To activate a paused build configuration, select Activate in the Actions menu.

Pausing / Activating several build configurations of a project

To pause several build configurations of a project:

  1. On the Project Settings page, open the Actions menu and click Pause/Activate.

  2. In the dialog that opens, select the box next to the project to pause all its build configurations or check the boxes of the configurations selectively: the checked build configurations will be paused.

  3. Add an optional comment.

  4. To remove all the builds of the paused configurations from the build queue, check the Cancel already queued builds if build configuration is paused box.

  5. Click Apply.

To activate several build configurations of a project:

  1. On the Project Settings page, open the Actions menu and click Pause/Activate.

  2. In the dialog that opens, clear the box next to the project to activate all its build configurations or clear the boxes of the configurations selectively: the unselected build configurations will be activated.

  3. Add an optional comment.

  4. Click Apply.

Build Configuration Status

In general, a build configuration status reflects the status of its last finished build.

Note that personal builds do not affect the build configuration status.

You can view the status of all build configurations on the Projects page (for all projects) or Project Home page (for a particular project), when the details are collapsed.

Build configuration status icons:

Icon

Description

Successful.png

The last build on default branch executed successfully.

Failed.png

The last build on the default branch executed with errors or one of the currently running builds is failing. The build configuration status will change to "failed" when there's at least one currently running and failing build, even if the last finished build was successful.

investigate.png

fix.png

Indicates that someone has started investigating the problem, or already fixed it. See Investigating and Muting Build Failures.

no icon

There were no finished builds for this configuration, the status is unknown.

paused.png

The build configuration is paused: all triggers are disabled, but the build can still be triggered manually or by dependencies.

To see who paused the configuration or to unpause it, click the link next to the status icon.

Status Display for Set of Build Configurations

It is possible to filter out the build configurations whose status you want to be displayed in TeamCity or externally.

To display the status of selected build configurations in TeamCity:

  • configure visible projects on the Projects page to display the status of build configurations belonging to these projects only

  • implement a custom Java plugin for TeamCity to make the page available as a part of the TeamCity web application

To display the status for a set of build configurations externally (on your company's website, wiki, Confluence, or any other web page), you can:

Last modified: 28 February 2021