Force Build on Specific Tag?

Mike-E's Avatar


27 Nov, 2019 12:16 PM

I am attempting to force a build after an external workflow has completed.

In regards to this question:

It would seem filters are ignored when this API call is invoked.

However, it would seem that the `branches.only` field _is_ respected, as I have configured the build definition to use separate configurations via the `for:` keyword, and the `master` branch selection is being built, as defined here:

However, naturally, this is not what I want. xD

This forced build is to simulate a tagged build, but there is no `tag` field in the api call. Is there a way to trigger a forced build with a specific tag?

FWIW, I am wanting to select this configuration:

  1. 1 Posted by Mike-E on 27 Nov, 2019 01:24 PM

    Mike-E's Avatar

    Looks like setting both the branch and commitID as the tag name will check out the branch as the tag:

    $body = @{
                 accountName = $env:DEPLOY_ACCOUNT
                 projectSlug = $env:DEPLOY_SLUG
                 branch = $tagName
                 commitId = $tagName

    However, the response still denotes that it is not in a tagged context:

    buildId : 29158162
    version :
    branch : 9.0.11
    isTag : False

    I am able to select the branch now. However, it would be nice to know if there is a way to fully simulate a "tagged" build when manually forcing it.

  2. Support Staff 2 Posted by Feodor Fitsner on 28 Nov, 2019 08:19 PM

    Feodor Fitsner's Avatar

    You can introduce some environment variable into new build API request, saying it's tag build.

  3. 3 Posted by Mike-E on 28 Nov, 2019 09:11 PM

    Mike-E's Avatar

    Alright. I was hoping/looking for something more official, but it sounds like there isn't... what we have will do, however, so no biggie.

  4. Mike-E closed this discussion on 28 Nov, 2019 09:11 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts


? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac