Reputation: 43
I am trying to create a Visual Studio Team Services Extension Task for my builds and releases. I need a task that will send out an alert to another system if a previous task (including the default build/test/publish/etc.) fails.
I have already created the task to send the alert. However I do not see a way to kick off the task only if my build fails.
Is there a way in VSTS to run a task if a previous task fails, but not run it if all other tasks were successful?
Upvotes: 3
Views: 1746
Reputation: 3119
It is now possible to select a running condition for all tasks with the following possible values:
EDIT:
It is currently part of a preview, you can enable it through the "Preview features" menu after you click on your profile click on VSTS:
And activate the "New Build Editor":
Upvotes: 3
Reputation: 114857
There is no built-in feature.
But you can use the "Rollback" task from the Release Management Utilities to run a powershell script on failure.
Upvotes: 2