diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 387b658a34c1b282218a6a2b287fd56bded53dd0..5eb3d8fc80cc4a8294868d6541a3c4e03f056ada 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -126,7 +126,14 @@ cleanup:
   tags:
     - firmware
   script:
-    - if [ -f skip_pipeline ]; then exit 0; fi  # Exit the job if marker file exists
+    - |
+      (
+        if [ -f skip_pipeline ]; then 
+          # Delete the current pipeline
+          curl --request DELETE --header "PRIVATE-TOKEN: $ACCESS_TOKEN" "https://git.ffnw.de/api/v4/projects/$CI_PROJECT_ID/pipelines/$CI_PIPELINE_ID";
+          exit 0;
+        fi  # Exit the job if marker file exists
+      )
     - touch .patched
     - ./buildscript.sh clean_patches
     - rm -rf ../output