diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index f0ba66573fd609e7814d8d1c641044baa4b05c75..205b36efb14b8cbdb4d83b0a0d4a30545d0fd182 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -20,7 +20,10 @@ metabuild:
     tags: [build]
     only:
         changes:
-            - pica-dokuwiki/*
+            - "pica-dokuwiki/*"
+        branches:
+            - master
+            - dev-ci
         
 # build the container that was modified
 build:
@@ -28,7 +31,6 @@ build:
     image: $REGISTRY_PROD/pica-ci:latest
     before_script:
         - echo $REGISTRY_PASSWORD | docker login $REGISTRY -u $REGISTRY_USERNAME --password-stdin
-        - echo $MODIFIED_IMAGE
         - source /etc/profile.d/ci-variables
     script:
         - docker build -f $MODIFIED_IMAGE/Dockerfile $MODIFIED_IMAGE -t $REGISTRY/ci-builds/$CI_COMMIT_SHA
@@ -38,7 +40,10 @@ build:
     tags: [build]
     only:
         changes:
-            - pica-dokuwiki/*
+            - "pica-dokuwiki/*"
+        branches:
+            - master
+            - dev-ci
 
 # run CoreOS' Clair and make the CI failed if a critical vulnerability isn't in the whitelist
 clair:
@@ -64,8 +69,10 @@ clair:
     tags: [build]
     only:
         changes:
-            - pica-dokuwiki/*
-    allow_failure: false
+            - "pica-dokuwiki/*"
+        branches:
+            - master
+            - dev-ci
 
 # run docker-bench-security and upload the results
 docker-bench-security:
@@ -95,7 +102,10 @@ docker-bench-security:
     tags: [build]
     only:
         changes:
-            - pica-dokuwiki/*
+            - "pica-dokuwiki/*"
+        branches:
+            - master
+            - dev-ci
 
 # automatically deploy the container on pica01-test
 deployment-test: 
@@ -124,7 +134,10 @@ deployment-test:
     tags: [build]
     only:
         changes:
-            - pica-dokuwiki/*
+            - "pica-dokuwiki/*"
+        branches:
+            - master
+            - dev-ci
 
 # automatically deploy the container on the production host associated with the modified image
 # this will only happen after manually triggering the deployment
@@ -158,5 +171,5 @@ deployment-prod:
     tags: [build]
     only:
         changes:
-            - pica-dokuwiki/*
+            - "pica-dokuwiki/*"
     when: manual
\ No newline at end of file