Downloading builds from TeamCity

12,143

Solution 1

What you're actually looking to do is create artifacts in TeamCity. Artifacts are normally a build output which are then attached to the individual build runs so that you can download and review them at a later date. There's a walk through including the creation of build artifacts in You're deploying it wrong! TeamCity, Subversion & Web Deploy part 5: Web Deploy with TeamCity.

Solution 2

You can use the build id, build number or one of the static build identifiers:

http://{TeamCity-Server}/repository/download/{BUILD_TYPE_ID}/{BUILD_NUMBER}/{ARTIFACT_PATH}

http://confluence.jetbrains.net/display/TCD65/Patterns+For+Accessing+Build+Artifacts

Share:
12,143
kasperhj
Author by

kasperhj

Updated on June 05, 2022

Comments

  • kasperhj
    kasperhj almost 2 years

    Is there a way to download specific builds of a project in TeamCity?

  • kasperhj
    kasperhj almost 13 years
    How do I set up TC to do this? Can it provide a listing of the different builds?
  • Bronumski
    Bronumski almost 13 years
    @lejon Can we confirm what it is you are trying to download. I got the impression that you are trying to download artifacts from a build, is this the case?
  • kasperhj
    kasperhj almost 13 years
    I'm sorry, I don't know what "artifacts" referes to.
  • Bronumski
    Bronumski almost 13 years
    @lejon What do you want to download, the output from a build or the source used for the build?
  • kasperhj
    kasperhj almost 13 years
    Both really. First the output though.
  • Bronumski
    Bronumski almost 13 years
    @lejon In order to get the output you need to store the output as artifacts. confluence.jetbrains.net/display/TCD65/Build+Artifact Once you have artifacts you can access them how I described above.
  • kasperhj
    kasperhj almost 13 years
    I have now tried adding some artifact paths to put the content of \bin in a separate directory (although the path is rather obscure). How can I reference this artifact from the outside, so my users always can download the latest version by entering a url?
  • Troy Hunt
    Troy Hunt almost 13 years
    I'm not near a TeamCity server this week so I'll have to speculate, but I think you'll find the URL is predictable and will contain a variable for the build number. There's also a REST API available that can be used to pull back build info which you might find useful: confluence.jetbrains.net/display/TW/REST+API+Plugin