diff --git a/awx/main/tasks.py b/awx/main/tasks.py index 7a408265d9..615eb90a4f 100644 --- a/awx/main/tasks.py +++ b/awx/main/tasks.py @@ -1569,9 +1569,11 @@ class BaseTask(object): res = list(first_future.done)[0].result() if res.status == 'canceled': + receptor_ctl.simple_command(f"work cancel {result['unitid']}") resultsock.shutdown(socket.SHUT_RDWR) resultfile.close() + receptor_ctl.simple_command(f"work release {result['unitid']}") status = res.status rc = res.rc