ADO Custom Requirement to update ServiceNow ChangeTasks under ChangeRequest - azure-devops-rest-api

Please find the ADO custom requirement(marked in yellow) to update the status of ServiceNow Change Tasks (CTASK) from ADO pipelines. The workflow is as below.
ServiceNow Change Management extension from Microsoft is configured in ADO release pipeline gates to create a new change request in Service Now tool.
The ServiceNow change request created by ADO release pipeline will also create multiple CTASKS under it.
The ServiceNow CTASKs should get closed from ADO tool based on approval step executed in ADO pipeline
Finally the release pipeline should update the status of ServiceNow Change request to closed once all the ServiceNow CTASKS and ADO pipeline tasks are completed

Related

bitbucket plugin in jenkins pipeline should have several repositories as trigger

We use several git repositories of sources for common builds. Because not only one, but several of them might be changed alone, we would need several repositories to be checked to trigger invocation of a jenkins pipeline script.
I guess, that others might also be interested in this kind of extended functionality. Any proposal/hint how to resolve this is highly appreciated.
We have not implemented yet the bitbucket plugin use, because this would be to incomplete to serve our needs now.
You could try using web hooks
Put your web hook at project level, and changes to repositories within the project will trigger the web hook.
Then on the Jenkins side you will need the Generic Webhook Plugin
Bitbucket sends a json payload to Jenkins which consumes the payload.
You can use the Json path expression tester to get relevant fields from the payload. From that you can decide what build should be triggered.
The newer way of doing this is to use the Bitbucket Server plugin for Jenkins

TFS With Jira - Any tools?

I'm looking at integrating TFS with JIRA. I Want to run my test cases in TFS but when i raise bugs i want them to automatically update on the JIRA board. Is there anything out there that can make this possible?
Also would it automatically block the test case and link the bug in JIRA with it?
There is no such kind of build in feature or extension. However, you could raise bugs in TFS/Azure DevOps first when you run your test cases. Then synchronize your bugs with issues in Jira. It's not able to directly link the bug in JIRA with TFS test cases.
You could choose to use TFS4JIRA Azure DevOps integration.
TFS4JIRA is migration, integration and synchronization tool, which
bridges TFS / Azure DevOps and Jira (Server/DC/Cloud). Integrate
Azure DevOps with TFS4JIRA, to view your project or issue-associated
Azure DevOps check-ins in Jira, as well as synchronize changes made to
the issues and integrate Azure Jira work items.
Create your individual TFS4JIRA sync profiles and define the project collections which you want to work with.
Map your issue types, work item types, fields, values.
Hierarchy and subtasks synchronisation supported.
Enable your profile and, voila! – the synchronizer is making sure that Jira and Azure DevOps exchange information in the background.
If you already have some bug/issue work items in JIRA and want to import them to TFS on-premise server. There is an extension named Jira to Azure DevOps/TFS work item migration tool. It is used to Azure DevOps work item migration tool lets you export data from Jira and import it as work items in Azure DevOps or Microsoft Team Foundation Server. Here is the download page.

TFS17 on prem and fortify builds

I need to incorporate a task in my build to perform a Fortify Scan. My issue is I have one agent and scans take 1 to 2 hours, which ties up the one agent. I then tried to create a build that would start a scan of are TFS/SCM only to kill it after it ran for over 8 hours. Is there a way to create a task that only runs the changes for that day?
Since you are using Team Foundation Server 2017. As part of your build and release process you could execute Micro Focus Fortify security scans and upload the results to the Fortify SSC server.
It's also able to make the build/release fail whenever the scanner detects new critical or high findings in the code. We could use the Micro Focus Fortify plugin for TFS to configure the scan step and upload to SSC: (Fortify TFS plugin). Just add a PowerShell task afterward to attempt to query for findings and fail the build if needed.
Is there a way to create a task that only runs the changes for that day? There is also a concept called Scheduled Trigger which select the days and times when you want to run the build. Just make sure to check "Only schedule builds if the source and pipeline has changed" All support triggers are list here --Build pipeline triggers, please kindly take a look at it.

How to retrieve the Agent for a specific Release

The TFS Rest API allows me to get a specific Release for a Team Project
Ex. https://bla.visualstudio.com/MySuperProject/_apis/release/releases/666
I already found, how to get the related Pool of the Release. But is it possible to retrieve the Agent where the Release was deployed using the TFS Rest API ?
Thanks
You can get the release with all the details by calling REST API as shown below. You should use youraccount.vsrm.visualstudio
https://yourVSTSAccount.vsrm.visualstudio.com/yourproject/_apis/release/releases/releaseid
example
https://myac.vsrm.visualstudio.com/Project%20X/_apis/release/releases/106
gives the release agent in deployment steps as shown below

Can TeamCity listen to tfs builds and trigger my automation tests

We are using team foundation server for checking in the code and building the project.
Now, we would like to add to TeamCity to trigger our automation suite as soon as a build is pushed to tfs.
Question:
Can TeamCity listen to TFS build information and call my automation scripts to execute? (I checked every where, it says teamcity performs build, I want tfs to perform a build and do post actions)
VSTS/TFS 2015 and later has the feature that integrating with your favorite services by notifying them when events happen in your project. It provides a way to send a JSON representation of an event to any service. More information: https://www.visualstudio.com/en-us/docs/integrate/get-started/service-hooks/services/webhooks
You need check on TeamCity side to see whether it can receive the JSON representation of an event from TFS.

Resources