0

In our company we have a TFS server used for CI tasks (build & release) and as a Source Control server (we use Git). I would like to put under version control the TFS build & release configurations, something like Jenkins Job Builder for Jenkins.

The tool I am searching for should not only act as a sort of backup, but should allow us to reconfigure TFS simply launching a CLI command (like jenkins job builder's jenkins-jobs command).

Is there anything out there which accomplish to this requirement?

Regards

gvdm
  • 3,006
  • 5
  • 35
  • 73

1 Answers1

1

Sorry, there are no similar things as Jenkins Job Builder for TFS by now.

There had been a related user voice: provide a way to version-control build definitions

We announced the public preview of YAML build definitions in VSTS. You can now author the build process in code. The preview only supports build not support with release. And this is also not available with on-premise TFS server by now.

More details please review: How to use YAML builds

As a workaround, you can simply export and import the build definitions in TFS 2017update2 and above. To update the build definition, you can use the REST API (Update a build definition) with the PUT method:

e.g.:

PUT http://server:8080/tfs/DefaultCollection/Project/_apis/build/definitions/29?api-version=2.0

Content-Type: application/json
{json body here}

Take a look at this related question: Does TFS 2017 have the ability to export and import build definitions into remote server?

PatrickLu-MSFT
  • 49,478
  • 5
  • 35
  • 62
  • Hi @PatrickLu-MSFT. We are using an on-premise TFS installation, so I do no expect to find this feature, right? Is there any plan to enhance this feature and let it be production-ready in the future? So your advice is to use the TFS client libraries or REST APIs? – gvdm May 16 '18 at 07:37
  • 1
    @gvdm Yes, even for VSTS, to use this capability, you must have the Build YAML definitions **preview feature** enabled on your account. Most new features are released to Visual Studio Team Services first and are integrated into Team Foundation Server with a bit of a delay. I'm not quiet sure about the specific time in the future. For now, you may have to use Rest APIs to handle this situation. There are many related tutorials in google. – PatrickLu-MSFT May 16 '18 at 07:47
  • 1
    Yes, I started developing my own "tfs-job-builder" which uses the TFS client library and REST APIs (where the client library lacks of features) to perform the configurations. – gvdm Jun 04 '18 at 08:49