REST API - Build Chain Issues

Hi All

Is there a way to run or re-run a specific build number or trigger a deployment in a chain from the REST API?  We use build chains heavily, re-running jobs from the chain if we need to re-deploy. We also have approvals in place so that version updates need to be approved before deployment but once that's been done, the jobs can be run at will. When launching builds from the REST API, it gets a new build number and the status of the latest chain does not change. Is there a way to make this happen? Example below, running dev plan from the API gets a new number each time and is not reflected in the build chain, which is only up to 80.

2 comments
Comment actions Permalink

I've just realised this is a bigger issue than I thought, kicking off a build with a new build number also causes the entire chain to run again! This won't work as our first step in the chain is to release the code to Artifactory but TC doesn't have delete permissions, so re-running will fail as the artifact with that version already exists and can't be overwritten. We also don't want every environment to run again if we are trying to deploy the DR environment.

0
Comment actions Permalink

I think I may have found the answer. In the XML, passing properties (called parameters in the UI) build.number and system.build.number did nothing but passing build.counter seems to do what I want.

0

Please sign in to leave a comment.