GitLab CI "interruptible" Not Cancelling Redundant Pipelines
interruptible: true lets GitLab auto-cancel a running pipeline when a newer commit supersedes it. It stops working once a non-interruptible job has started, or when the project auto-cancel setting is disabled.
What this error means
Pushing a new commit does not cancel the older still-running pipeline, so redundant pipelines pile up and waste runner minutes - even though jobs are marked interruptible.
# New commit pushed, but the previous pipeline keeps running.
test:
interruptible: true
script: make test
deploy:
script: make deploy # NOT interruptible -> locks the whole pipelineCommon causes
A non-interruptible job already started
Once any job without interruptible: true begins running, GitLab will no longer auto-cancel that pipeline - the whole pipeline becomes non-interruptible from that point.
Auto-cancel-redundant setting disabled
Auto-cancellation of redundant pipelines is a project CI/CD setting. If it is off, interruptible has no effect regardless of how jobs are marked.
How to fix it
Mark early jobs interruptible, gate deploys
Keep build/test interruptible and make irreversible jobs (deploys) manual or late so they do not start before cancellation can happen.
default:
interruptible: true # applies to all jobs by default
deploy:
interruptible: false # protect a real deployment from cancellation
when: manual
script: make deployEnable auto-cancel in project settings
- Open Settings → CI/CD → General pipelines.
- Enable "Auto-cancel redundant pipelines".
- Confirm early jobs are
interruptibleso a newer commit cancels the older pipeline before deploy starts.
How to prevent it
- Set
interruptible: trueviadefault:for build/test jobs. - Keep irreversible jobs (deploy/release) non-interruptible and gated.
- Enable auto-cancel redundant pipelines at the project level.