Terraform · Arazzo Workflow
Terraform Find and Cancel a Stuck Run
Version 1.0.0
Locate an in-flight run on a workspace, cancel it, and unlock the workspace.
View Spec
View on GitHub
Infrastructure As CodeCloud InfrastructureDevOpsOpen SourceHashiCorpArazzoWorkflows
Provider
Workflows
cancel-stuck-run
Cancel an in-progress run on a workspace and release the workspace lock.
Lists the workspace's runs filtered to an in-flight status, reads the newest match, cancels it, waits for the cancellation to settle, and unlocks the workspace.
1
findInFlightRun
ListWorkspaceRuns
List the workspace's runs filtered to the supplied in-flight status, newest first, taking only the most recent match.
2
readRun
GetRun
Read the matched run to confirm it is genuinely still in flight and has not settled on its own since the list call.
3
cancelRun
CancelRun
Cancel the in-progress run, recording why it was cancelled so the run history explains the intervention.
4
pollCancellation
GetRun
Poll the run until the cancellation is reflected in its status, repeating while the run is still winding down.
5
unlockWorkspace
UnlockWorkspace
Unlock the workspace so the next run can be queued, since a cancelled run can leave the workspace locked behind it.