Run `after_script` even when the job is cancelled for gracefully interruptible jobs
In gitlab#15603 GitLab will allow users to make the cancel button stop the execution of the job in any of the stages, and starts executing the
upload_artifacts_on_success/failure. It will be done through
At the moment when GitLab has a canceled job, GitLab Runner will see that when on sending the trace and will cancel everything on any stage that it is currently in and stop the build.
With gitlab#15603 Gitlab will add a new setting for jobs:
interruptible: graceful which would mean that upon cancellation
after_script should still run.
To communicate it with the runner a new value for
Step will be introduced in the
requestJob endpoint -
The runner should not stop
after_script on cancel if
upload_artifacts_on_failure will follow what
after_script does until they become steps of their own (discussion: #6409 (comment 329983777))
Stage which is cancellable from the UI:
Stages that run after the job was canceled from the UI (