Sam Rueby
Sam Rueby

Reputation: 6129

How to prevent TeamCity from storing build artifacts?

TeamCity automatically stores files it believes are build artifacts. All of our artifacts are stored in Octopus Deploy, so this is unnecessary.

How do you configure TeamCity not to store build artifacts?

Upvotes: 1

Views: 1276

Answers (2)

Sam Rueby
Sam Rueby

Reputation: 6129

TeamCity doesn't store build artifacts by default.

Confirmed by Julia Reshetnikova in a support ticket:

What's happening is that a build step is pushing the artifacts using service messages. Configure the build steps to not push artifacts.

If the build steps do not allow configuring this, then the best thing you can do is configure a clean-up rule to remove build artifacts as fast as possible.

  1. Go to the settings
  2. Click on Clean-up Rules in the left navigation.
  3. You may see multiple "build configuration or template", for each:
  4. Click Edit.
  5. Under "Clean Artifacts", choose custom policy.
  6. Choose 1 days since last build or "1th" successful build, whichever makes the most sense to you.

All subprojects under will inherit this configuration. After this is configured, you can force TeamCity to run a cleanup by:

  1. Go to the Administration page
  2. Choose Clean-up Settings in the left navigation
  3. Click "Start clean-up now"

Upvotes: 1

Senior Pomidor
Senior Pomidor

Reputation: 1915

If you do not want to save artifacts, just remove Artifact paths from all projects

One more suggestion. Open Global Settings, sets Maximum build artifact file size to 0 Kb

Also, you can clean all the collected data

go to Administration > Server Administration > Clean-up Settings

The Previous clean-up section of the server clean-up settings enables you to:

  • review the information on the previous server clean-up date and duration helping you decide whether to launch the clean-up process at a given moment
  • run clean-up manually using the Start clean-up now button

During clean-up, TeamCity reports the progress. If you need, you can stop the clean-up process and the remaining data will be removed during the next clean-up.

Just press the button Start clean-up now

enter image description here

Upvotes: 1

Related Questions